restpack-core-client 0.1.9 → 0.1.10

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.
@@ -15,7 +15,7 @@ module RestPack
15
15
  def get_channel(id)
16
16
  p "API.get_channel(#{id})"
17
17
  json = RestClient.get("http://:#{@access_key}@#{@domain}/api/v1/channels/#{id}.json")
18
- data = JSON.parse(json, :symbolize_keys => true)
18
+ data = Yajl::Parser.parse(json, :symbolize_keys => true)
19
19
 
20
20
  hydrate_channel(data)
21
21
  end
@@ -23,13 +23,13 @@ module RestPack
23
23
  def get_domain(host)
24
24
  p "API.get_domain(#{host})"
25
25
  json = RestClient.get("http://:#{@access_key}@#{@domain}/api/v1/domains/search.json?host=#{host}")
26
- result = JSON.parse(json, :symbolize_keys => true)
26
+ result = Yajl::Parser.parse(json, :symbolize_keys => true)
27
27
 
28
28
  raise "host is not configured: #{host}" if result.empty?
29
29
 
30
30
  p "result: #{result}"
31
- p "found domains: #{result[:domains]}"
32
- p "first domain: #{result[:domains].first}"
31
+ p "found domains: #{result['domains']}"
32
+ p "first domain: #{result['domains'].first}"
33
33
 
34
34
  result[:domains].first
35
35
  end
@@ -1,7 +1,7 @@
1
1
  module RestPack
2
2
  module Core
3
3
  module Client
4
- VERSION = "0.1.9"
4
+ VERSION = "0.1.10"
5
5
  end
6
6
  end
7
7
  end
@@ -2,4 +2,4 @@ require 'restpack-core-client/version'
2
2
  require 'restpack-core-client/api'
3
3
  require 'restpack-core-client/cache'
4
4
  require 'rest_client'
5
- require 'yajl/json_gem'
5
+ require 'yajl'
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: restpack-core-client
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.9
4
+ version: 0.1.10
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors: