zendesk_apps_support 1.17.1 → 1.17.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: 4652177f210c7e96e96dda1dd85b981b2d9017c1
4
- data.tar.gz: 707731e9c4eb073339dc46ba1529416b43d63aa0
3
+ metadata.gz: 5a4456bc6e8b042ab159e7cdc95c70343796525d
4
+ data.tar.gz: 1277915e7d74645722c62932010cee346b3ea580
5
5
  SHA512:
6
- metadata.gz: 8b31cb09a925f5987c82290c4f4cae89ea09e41ade156db05bd1409d20a4f6e4bb7426ef2cf1710f892579ea5be834b211e863a11a7547d0ba7459518c31c054
7
- data.tar.gz: 3b3d587b40cebbcbfba5d704371eb83c8bcd4d3395fe64243ebddf50e3b292d98427ee7fc0b60b91c0d8151ad8d8ee7089cb6b907d6022feb46a39b05075da53
6
+ metadata.gz: b6d3dc0bd36bdefde2f8896189a544281bfa81d791f79f43104024486adbe6593426e00f08d0d3cdc811188a972e0ba80d44282d7c772b0c6fc37b6216c7c95b
7
+ data.tar.gz: 9998cd1f7bdbc622567685375453090868296c3fabacfaa119f20c27628f5de5b456f52d8c6c5aafe69a109b6439ae6724e0c27c0e48501aa9ebc0e26101d724
@@ -1,4 +1,4 @@
1
- require 'multi_json'
1
+ require 'json'
2
2
 
3
3
  module ZendeskAppsSupport
4
4
  # At any point in time, we support up to three versions:
@@ -52,7 +52,7 @@ module ZendeskAppsSupport
52
52
  end
53
53
 
54
54
  def to_json(*)
55
- MultiJson.encode(@version)
55
+ @version.inspect
56
56
  end
57
57
 
58
58
  def ==(other)
@@ -1,4 +1,4 @@
1
- require 'multi_json'
1
+ require 'json'
2
2
 
3
3
  module ZendeskAppsSupport
4
4
  module Validations
@@ -14,7 +14,7 @@ module ZendeskAppsSupport
14
14
 
15
15
  return [ValidationError.new(:missing_manifest)] unless manifest
16
16
 
17
- manifest = MultiJson.load(manifest.read)
17
+ manifest = JSON.load(manifest.read)
18
18
 
19
19
  [].tap do |errors|
20
20
  errors << missing_keys_error(manifest)
@@ -40,7 +40,7 @@ module ZendeskAppsSupport
40
40
 
41
41
  errors.compact!
42
42
  end
43
- rescue MultiJson::DecodeError => e
43
+ rescue JSON::ParserError => e
44
44
  return [ValidationError.new(:manifest_not_json, errors: e)]
45
45
  end
46
46
 
@@ -1,4 +1,4 @@
1
- require 'multi_json'
1
+ require 'json'
2
2
  require 'json/stream'
3
3
 
4
4
  module ZendeskAppsSupport
@@ -18,7 +18,7 @@ module ZendeskAppsSupport
18
18
  return [ValidationError.new(:duplicate_requirements, duplicate_keys: duplicates.join(', '), count: duplicates.length)]
19
19
  end
20
20
 
21
- requirements = MultiJson.load(requirements_stream)
21
+ requirements = JSON.load(requirements_stream)
22
22
  [].tap do |errors|
23
23
  errors << invalid_requirements_types(requirements)
24
24
  errors << excessive_requirements(requirements)
@@ -26,7 +26,7 @@ module ZendeskAppsSupport
26
26
  errors.flatten!
27
27
  errors.compact!
28
28
  end
29
- rescue MultiJson::DecodeError => e
29
+ rescue JSON::ParserError => e
30
30
  return [ValidationError.new(:requirements_not_json, errors: e)]
31
31
  end
32
32
 
@@ -1,4 +1,5 @@
1
1
  require 'jshintrb'
2
+ require 'json'
2
3
 
3
4
  module ZendeskAppsSupport
4
5
  module Validations
@@ -27,7 +28,7 @@ module ZendeskAppsSupport
27
28
  end
28
29
 
29
30
  def json_error(file)
30
- json = MultiJson.load(file.read)
31
+ json = JSON.load(file.read)
31
32
  if json.is_a?(Hash)
32
33
  if json['app'] && json['app']['package']
33
34
  json['app'].delete('package')
@@ -41,7 +42,7 @@ module ZendeskAppsSupport
41
42
  else
42
43
  ValidationError.new('translation.not_json_object', file: file.relative_path)
43
44
  end
44
- rescue MultiJson::DecodeError => e
45
+ rescue JSON::ParserError => e
45
46
  ValidationError.new('translation.not_json', file: file.relative_path, errors: e)
46
47
  end
47
48
 
@@ -1,4 +1,4 @@
1
- require 'multi_json'
1
+ require 'json'
2
2
 
3
3
  module ZendeskAppsSupport
4
4
  module Validations
@@ -14,10 +14,10 @@ module ZendeskAppsSupport
14
14
  class << self
15
15
  # Turn a JSON string into a ValidationError.
16
16
  def from_json(json)
17
- hash = MultiJson.decode(json)
17
+ hash = JSON.load(json)
18
18
  fail DeserializationError.new(json) unless hash.is_a?(Hash)
19
19
  from_hash(hash)
20
- rescue MultiJson::DecodeError, NameError
20
+ rescue JSON::ParserError, NameError
21
21
  raise DeserializationError.new(json)
22
22
  end
23
23
 
@@ -51,7 +51,7 @@ module ZendeskAppsSupport
51
51
  end
52
52
 
53
53
  def to_json(*)
54
- MultiJson.encode(as_json)
54
+ JSON.generate(as_json)
55
55
  end
56
56
 
57
57
  def as_json(*)
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: zendesk_apps_support
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.17.1
4
+ version: 1.17.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - James A. Rosen
@@ -11,7 +11,7 @@ authors:
11
11
  autorequire:
12
12
  bindir: bin
13
13
  cert_chain: []
14
- date: 2015-02-16 00:00:00.000000000 Z
14
+ date: 2015-03-30 00:00:00.000000000 Z
15
15
  dependencies:
16
16
  - !ruby/object:Gem::Dependency
17
17
  name: i18n
@@ -27,20 +27,6 @@ dependencies:
27
27
  - - ">="
28
28
  - !ruby/object:Gem::Version
29
29
  version: '0'
30
- - !ruby/object:Gem::Dependency
31
- name: multi_json
32
- requirement: !ruby/object:Gem::Requirement
33
- requirements:
34
- - - ">="
35
- - !ruby/object:Gem::Version
36
- version: '0'
37
- type: :runtime
38
- prerelease: false
39
- version_requirements: !ruby/object:Gem::Requirement
40
- requirements:
41
- - - ">="
42
- - !ruby/object:Gem::Version
43
- version: '0'
44
30
  - !ruby/object:Gem::Dependency
45
31
  name: sass
46
32
  requirement: !ruby/object:Gem::Requirement
@@ -205,7 +191,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
205
191
  version: 1.3.6
206
192
  requirements: []
207
193
  rubyforge_project:
208
- rubygems_version: 2.2.2
194
+ rubygems_version: 2.4.6
209
195
  signing_key:
210
196
  specification_version: 4
211
197
  summary: Support to help you develop Zendesk Apps.