epom 0.10 → 0.10.5

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: b4c396bb9de8ec04b2572fd46c76ce69f2ca4c75
4
- data.tar.gz: 3f2f59811305247d84c8767e8a0e60085dbadc3d
3
+ metadata.gz: eca8257d4dd0fc05b44c2dbade609a3f8e1b48d9
4
+ data.tar.gz: 6916068283eb472800ca1149ab8957fbcc7d19e5
5
5
  SHA512:
6
- metadata.gz: 067dc225a6ba0bf2f76dc518dde729036c77ea8938e015d5df5384205572345b63e6d4c0509afcde668797f3b80460b047b24d1e7d956810d186c3eeac788397
7
- data.tar.gz: e75e598ad49c41f8d198c51487482844dd7f00fa3e17c753da835985570453a08a949fc8e2d0b7cc554be906d3d645e2bb0d33a3b36b3c7ea8995261a153eb9d
6
+ metadata.gz: c8bc9f840980ad18190864176f1af3b0a5d10911c5ffa03c54e90a7d60ed1cd022f34abf52a237f9c4fa499db8d2906c2dbb4680de2e817ae4dd56ae863631c6
7
+ data.tar.gz: aec28b3cc0957edd83531105394131821fc062c20a1b3eb939a20fcfd473d8a1f77097f8ea6e09edd3c96418735f84ca63b8b8093874b364d205561428973e05
data/lib/epom.rb CHANGED
@@ -3,6 +3,7 @@ require 'digest'
3
3
 
4
4
  require 'epom/ad_unit'
5
5
  require 'epom/advertiser'
6
+ require 'epom/analytic'
6
7
  require 'epom/auth'
7
8
  require 'epom/banner'
8
9
  require 'epom/campaign'
@@ -30,7 +30,6 @@ module Epom
30
30
  url_params.symbolize_keys! if url_params.is_a? Hash
31
31
  body_params.symbolize_keys! if body_params.is_a? Hash
32
32
 
33
- url = replace_params_in_url(url_signature, url_params)
34
33
  method = signature[:method]
35
34
 
36
35
  if signature[:headers]
@@ -55,10 +54,22 @@ module Epom
55
54
  if body_params_signature.include?(:username) and not body_params[:username]
56
55
  body_params[:username] = Epom.config.username
57
56
  end
57
+
58
+ if url_params_signature and url_params_signature.include?(:login) and not url_params[:login]
59
+ url_params[:login] = Epom.config.username
60
+ end
61
+ if url_params_signature and url_params_signature.include?(:hash) and not url_params[:hash]
62
+ url_params[:hash] = Epom.create_hash(Epom.create_hash(Epom.config.password), timestamp)
63
+ end
64
+ if url_params_signature and url_params_signature.include?(:timestamp) and not url_params[:timestamp]
65
+ url_params[:timestamp] = timestamp
66
+ end
58
67
 
59
68
  if params_validation(url_params, url_params_signature) and params_validation(body_params, body_params_signature)
60
69
  http_proxy Epom.config.proxy_address, Epom.config.proxy_port, Epom.config.proxy_user, Epom.config.proxy_password
61
70
  base_uri Epom.config.epom_server
71
+ url = replace_params_in_url(url_signature, url_params)
72
+
62
73
  puts method_name
63
74
  response = send(method, url, :query => body_params)
64
75
  if response.success?
data/lib/epom/version.rb CHANGED
@@ -1,3 +1,3 @@
1
1
  module Epom
2
- VERSION = '0.10'
2
+ VERSION = '0.10.5'
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: epom
3
3
  version: !ruby/object:Gem::Version
4
- version: '0.10'
4
+ version: 0.10.5
5
5
  platform: ruby
6
6
  authors:
7
7
  - Pedro Quintero
@@ -10,7 +10,7 @@ authors:
10
10
  autorequire:
11
11
  bindir: bin
12
12
  cert_chain: []
13
- date: 2015-08-16 00:00:00.000000000 Z
13
+ date: 2015-08-27 00:00:00.000000000 Z
14
14
  dependencies:
15
15
  - !ruby/object:Gem::Dependency
16
16
  name: rails