shoplo-api 0.0.1 → 0.0.2

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: c0a970fa7348e2e9912aeb695482ed8051773baf
4
- data.tar.gz: c78be36583aa5590a9a19ef9487db05df8f91a13
3
+ metadata.gz: 5f2b9377a3ef6d70859a9b66c2173ef11badbddd
4
+ data.tar.gz: 2ba832d572a09384530cdbc5a456e3573755603b
5
5
  SHA512:
6
- metadata.gz: 838a20e3a1eb8a5370129902ec6a12a50492376d39953344b66a76b4499572081d1ff0a057b4d56c0bd3925d4259363a9370e4f82f07706559528f3666920b31
7
- data.tar.gz: b84f9d5e150f28c3bbdba0746b8e62bd5b264e9ca5353e4838af4c8dea4b67bb5ab996fc6c38adb99454d159bd76bbfd9ec804a11b2836e291e132871e90d9d8
6
+ metadata.gz: 2d12a50a76ae71a441d9927ff820948d0b8343642ac177c80b2014e14994683ba706f3c2c2a4b8aa3bb8961996f6e49c7e781facec8dcae0ae61d764f6a1c365
7
+ data.tar.gz: 5ca32cacc3e7950ee60b9ca52901b0b4d57c68931ce0034ad7a92eab61f9c39d4f4697a8ffe80c34ee6859f379e4c66352c32ab6bb6431f609126f64a0e3cc5f
@@ -0,0 +1,13 @@
1
+ language: ruby
2
+ rvm:
3
+ - 2.2
4
+ - 2.3
5
+ deploy:
6
+ provider: rubygems
7
+ gem: shoplo-api
8
+ on:
9
+ branch: master
10
+ repo: YotpoLtd/shoplo-api
11
+ rvm: 2.3
12
+ api_key:
13
+ secure: ownc9XVwmDswMaVGFHX4HRpbDn6lcN6Td74TdERKibyAT+Yrm4k16gY0EKEqQb2Bo5PprzQnKvjU8evVlVhTyncRZPuz99IznJYiu+i1OA/d4RsaWvr7i0wkAzD/TXxPtONF+FXn6RIjlxc7ZY0VCcMKGF9DNhUtekWk/FUlhj0=
data/Rakefile CHANGED
@@ -1 +1,3 @@
1
1
  require "bundler/gem_tasks"
2
+
3
+ task default: :build
@@ -35,7 +35,11 @@ module Shoplo
35
35
  def get_content(type, params = {})
36
36
  id = params.delete(:id).to_i
37
37
  id = '' if id <= 0
38
- response = connection.get("/#{type}/#{id}?#{URI.encode_www_form(params)}")
38
+ _uri = "/#{type}"
39
+ _uri += "/#{id}" unless id.to_s.empty?
40
+ _params = URI.encode_www_form(params)
41
+ _uri += "?#{_params}" unless params.to_s.empty?
42
+ response = connection.get(_uri)
39
43
  json = Oj.load(response.body, mode: :compat)
40
44
 
41
45
  raise HTTPUnauthorized.new(json['error_msg']) unless json['error'].nil?
@@ -1,3 +1,3 @@
1
1
  module Shoplo
2
- VERSION = '0.0.1'
2
+ VERSION = '0.0.2'
3
3
  end
metadata CHANGED
@@ -1,69 +1,69 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: shoplo-api
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.1
4
+ version: 0.0.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Max Gulyaev
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2013-11-05 00:00:00.000000000 Z
11
+ date: 2018-06-12 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler
15
15
  requirement: !ruby/object:Gem::Requirement
16
16
  requirements:
17
- - - ~>
17
+ - - "~>"
18
18
  - !ruby/object:Gem::Version
19
19
  version: '1.3'
20
20
  type: :development
21
21
  prerelease: false
22
22
  version_requirements: !ruby/object:Gem::Requirement
23
23
  requirements:
24
- - - ~>
24
+ - - "~>"
25
25
  - !ruby/object:Gem::Version
26
26
  version: '1.3'
27
27
  - !ruby/object:Gem::Dependency
28
28
  name: rake
29
29
  requirement: !ruby/object:Gem::Requirement
30
30
  requirements:
31
- - - '>='
31
+ - - ">="
32
32
  - !ruby/object:Gem::Version
33
33
  version: '0'
34
34
  type: :development
35
35
  prerelease: false
36
36
  version_requirements: !ruby/object:Gem::Requirement
37
37
  requirements:
38
- - - '>='
38
+ - - ">="
39
39
  - !ruby/object:Gem::Version
40
40
  version: '0'
41
41
  - !ruby/object:Gem::Dependency
42
42
  name: oj
43
43
  requirement: !ruby/object:Gem::Requirement
44
44
  requirements:
45
- - - ~>
45
+ - - "~>"
46
46
  - !ruby/object:Gem::Version
47
47
  version: '2.0'
48
48
  type: :runtime
49
49
  prerelease: false
50
50
  version_requirements: !ruby/object:Gem::Requirement
51
51
  requirements:
52
- - - ~>
52
+ - - "~>"
53
53
  - !ruby/object:Gem::Version
54
54
  version: '2.0'
55
55
  - !ruby/object:Gem::Dependency
56
56
  name: oauth
57
57
  requirement: !ruby/object:Gem::Requirement
58
58
  requirements:
59
- - - '>='
59
+ - - ">="
60
60
  - !ruby/object:Gem::Version
61
61
  version: '0'
62
62
  type: :runtime
63
63
  prerelease: false
64
64
  version_requirements: !ruby/object:Gem::Requirement
65
65
  requirements:
66
- - - '>='
66
+ - - ">="
67
67
  - !ruby/object:Gem::Version
68
68
  version: '0'
69
69
  description: Ruby wrapper for shoplo API - written by Yotpo
@@ -73,7 +73,8 @@ executables: []
73
73
  extensions: []
74
74
  extra_rdoc_files: []
75
75
  files:
76
- - .gitignore
76
+ - ".gitignore"
77
+ - ".travis.yml"
77
78
  - Gemfile
78
79
  - LICENSE.txt
79
80
  - README.md
@@ -97,17 +98,17 @@ require_paths:
97
98
  - lib
98
99
  required_ruby_version: !ruby/object:Gem::Requirement
99
100
  requirements:
100
- - - '>='
101
+ - - ">="
101
102
  - !ruby/object:Gem::Version
102
103
  version: '0'
103
104
  required_rubygems_version: !ruby/object:Gem::Requirement
104
105
  requirements:
105
- - - '>='
106
+ - - ">="
106
107
  - !ruby/object:Gem::Version
107
108
  version: '0'
108
109
  requirements: []
109
110
  rubyforge_project:
110
- rubygems_version: 2.0.6
111
+ rubygems_version: 2.6.14
111
112
  signing_key:
112
113
  specification_version: 4
113
114
  summary: Ruby wrapper for shoplo API - written by Yotpo