planvine 0.0.5 → 0.0.6

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: b9f36fc737f030f9c7c173f1bb2a99adaab88e92
4
- data.tar.gz: 8408e0c868f7b034520b0d4548dafa8202a8d2f3
3
+ metadata.gz: 2948741dc03c75b3bc32f5756ef604c2bc4dbe1a
4
+ data.tar.gz: 0a02049fe4e168dc15722c04870a465caed298ed
5
5
  SHA512:
6
- metadata.gz: 0042c3208b8b3a25c6b92697b12472ea39b4cddc0b706cbb6222b32fd35a52458554b5f7b6eeee943696c43534360f7a54b44c28df5e1c835e29eaff612c1f2e
7
- data.tar.gz: 062968ce0652fe3233e3d4e655d46c079d4cdd7db7e2ce5061685c1d98faf2f9d0ccad8752686efe80f96e7bb0b57bda5a6f14db45d91d85bcf638a6f3607092
6
+ metadata.gz: eb1a319810a3bb4b16358d882a100a11b7b31d5d436e999d3fac4599f9b74bdcf0a28100ca4b78061089be3eba89e9a9101b10af8342490198b9dd917414ad72
7
+ data.tar.gz: d0af9e1513a2e6562b0524f095b1f943db8caf8bd73fbf83d5fd38afb948c4228ee82f54560329fdc457b23800bec8288b5d567ee2e0446d5ff19d026d3bc88a
@@ -1,6 +1,7 @@
1
1
  module Planvine
2
2
  class PlanvineAPI
3
3
  include HTTParty
4
+ format :json
4
5
  base_uri 'http://planvine.com/api/v1'
5
6
 
6
7
  def initialize(api_key)
@@ -15,13 +16,13 @@ module Planvine
15
16
 
16
17
  def categories
17
18
  categories = self.class.get("/category?api_key=#{@api_key}")
18
- JSON.parse(categories)["data"].map do |category|
19
+ categories["data"].map do |category|
19
20
  CategoriesBuilder.build(category, self)
20
21
  end
21
22
  end
22
23
 
23
24
  def category_events(id)
24
- JSON.parse(self.class.get("/category/#{id}/events?api_key=#{@api_key}"))["data"]
25
+ self.class.get("/category/#{id}/events?api_key=#{@api_key}")["data"]
25
26
  end
26
27
  end
27
28
  end
@@ -1,3 +1,3 @@
1
1
  module Planvine
2
- VERSION = "0.0.5"
2
+ VERSION = "0.0.6"
3
3
  end
data/planvine.gemspec CHANGED
@@ -19,7 +19,6 @@ Gem::Specification.new do |spec|
19
19
  spec.require_paths = ["lib"]
20
20
 
21
21
  spec.add_dependency "httparty"
22
- spec.add_dependency "json"
23
22
  spec.add_development_dependency "bundler", "~> 1.3"
24
23
  spec.add_development_dependency "rake"
25
24
  spec.add_development_dependency "rspec"
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: planvine
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.5
4
+ version: 0.0.6
5
5
  platform: ruby
6
6
  authors:
7
7
  - Richard Patching
@@ -24,20 +24,6 @@ dependencies:
24
24
  - - '>='
25
25
  - !ruby/object:Gem::Version
26
26
  version: '0'
27
- - !ruby/object:Gem::Dependency
28
- name: json
29
- requirement: !ruby/object:Gem::Requirement
30
- requirements:
31
- - - '>='
32
- - !ruby/object:Gem::Version
33
- version: '0'
34
- type: :runtime
35
- prerelease: false
36
- version_requirements: !ruby/object:Gem::Requirement
37
- requirements:
38
- - - '>='
39
- - !ruby/object:Gem::Version
40
- version: '0'
41
27
  - !ruby/object:Gem::Dependency
42
28
  name: bundler
43
29
  requirement: !ruby/object:Gem::Requirement