riq 1.2.2 → 1.2.3

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: 6136c5fd54ce8c3defd3fa0fbae6a8f2084ebbc5
4
- data.tar.gz: ed279d5a24bdda5b71410e40df1e04f8ed209ca9
3
+ metadata.gz: 44e1a65cfe5ee7fd358a1e2501dcf0b8337c3009
4
+ data.tar.gz: a54186ee04fdaadc5108f555b2f3f52a216add48
5
5
  SHA512:
6
- metadata.gz: 4a4e64454749eb8f2a69022e1491fce1d3ea9ac0a0608e1cb04c675b379c103e3cacf7e6fa95ddc4f2ca37bc83c9d9962f37dfa93ffb484f284ea4a44dd6ee75
7
- data.tar.gz: c4085e4a073aa080be3edb01831c681599b2851f5601c2360801dbb671481edc26fe99784657987c61f36eb0ae9f78dc8dc94492fd174cc6ce66a704dbe2935c
6
+ metadata.gz: 49728059e9bfef8a878b4eca7f56b66f754c5f8c7af4d9184d11c6553bfb4bfd1511015b533e9b5cabe94416efa7a9dddb9337ec2faf875c166077ef35364d17
7
+ data.tar.gz: a95180127bac0e331297a5b27a74eb5ac34c113f90bb6b5c7a3b961b783cf83f7e069e14f79dc4a67459690c56426cd20b78e3eaa7526fa3f25766deb2858266
data/.travis.yml CHANGED
@@ -1,8 +1,13 @@
1
1
  language: ruby
2
2
  rvm:
3
- # could add more here- what's a good spread?
3
+ # tested all on versions that work on heroku:
4
+ # https://devcenter.heroku.com/articles/ruby-support#ruby-versions
4
5
  - 2.0.0
5
- - 2.1.2
6
+ - 2.1.7
6
7
  - 2.2.3
7
8
  install: bundle install
8
9
  script: rake test
10
+ notifications:
11
+ email:
12
+ on_success: never
13
+ on_failure: always # the default, but good to mark here
data/README.md CHANGED
@@ -45,5 +45,5 @@ Copy `.env.example` to `.env` and edit to add your SalesforceIQ account credenti
45
45
 
46
46
  ## Helpful Links
47
47
 
48
- * [Full ruby docs](http://www.rubydoc.info/gems/riq)
48
+ * [Full ruby documentation](http://www.rubydoc.info/gems/riq)
49
49
  * [Examples and API docs](https://api.salesforceiq.com/#/ruby)
data/lib/riq/contact.rb CHANGED
@@ -62,13 +62,13 @@ module RIQ
62
62
  return
63
63
  end
64
64
 
65
- raise RIQError, 'Values must be strings' unless val.is_a? String
65
+ raise RIQError, 'Values must be strings' unless val.is_a?(String)
66
66
 
67
67
  # don't add duplicate
68
68
  if @properties[prop].select{|p| p[:value] == val}.empty?
69
69
  @properties[prop] << {value: val, metadata: {}}
70
70
  end
71
- send(prop)
71
+ get_prop(prop)
72
72
  end
73
73
 
74
74
  # Removes property from hash
@@ -88,7 +88,7 @@ module RIQ
88
88
  if @properties.include? prop
89
89
  @properties[prop] = @properties[prop].reject{|p| p[:value] == val}
90
90
  end
91
- send(prop)
91
+ get_prop(prop)
92
92
  end
93
93
 
94
94
  # Edits an existing object based on matching email(s) or saves a new object
@@ -114,7 +114,7 @@ module RIQ
114
114
  @modified_date = obj[:modified_date].cut_milis if obj[:modified_date]
115
115
  @properties = {}
116
116
  obj[:properties].each do |k,v|
117
- raise RIQError, "Properties must be arrays, #{k} wasn't" if !v.is_a?(Array)
117
+ raise RIQError, "Properties must be arrays, #{k} wasn't" unless v.is_a?(Array)
118
118
 
119
119
  v.each do |i|
120
120
  unless i.is_a?(Hash)
@@ -134,11 +134,11 @@ module RIQ
134
134
 
135
135
  # unused because we actually put all sorts of stuff in there
136
136
  def validate(prop)
137
- raise RIQError, %q(Invalid property. Use [:name | :phone | :email | :address] instead) unless [:name, :phone, :email, :address].include? prop
137
+ raise RIQError, %q(Invalid property. Use [:name | :phone | :email | :address] instead) unless [:name, :phone, :email, :address].include?(prop)
138
138
  end
139
139
 
140
140
  def get_prop(prop)
141
- if @properties.include? prop
141
+ if @properties.include?(prop)
142
142
  @properties[prop].map{|p| p[:value]}
143
143
  else
144
144
  []
data/riq.gemspec CHANGED
@@ -2,11 +2,11 @@
2
2
 
3
3
  Gem::Specification.new do |spec|
4
4
  spec.name = 'riq'
5
- spec.version = '1.2.2'
5
+ spec.version = '1.2.3'
6
6
  spec.authors = ['David Brownman']
7
7
  spec.email = ['david@relateiq.com']
8
8
  spec.homepage = "https://github.com/relateiq/ruby-sdk"
9
- spec.summary = 'Ruby RIQ API client'
9
+ spec.summary = 'Ruby SalesforceIQ API client'
10
10
  spec.description = 'Full featured ruby client for interacting with the SalesforceIQ API'
11
11
  spec.license = 'MIT'
12
12
  # this works for only adding committed files, but new files don't work until they're committed.
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: riq
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.2.2
4
+ version: 1.2.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - David Brownman
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2015-10-20 00:00:00.000000000 Z
11
+ date: 2015-10-22 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: httparty
@@ -151,8 +151,8 @@ required_rubygems_version: !ruby/object:Gem::Requirement
151
151
  version: '0'
152
152
  requirements: []
153
153
  rubyforge_project:
154
- rubygems_version: 2.4.8
154
+ rubygems_version: 2.4.5.1
155
155
  signing_key:
156
156
  specification_version: 4
157
- summary: Ruby RIQ API client
157
+ summary: Ruby SalesforceIQ API client
158
158
  test_files: []