webflow-ruby 0.1.1 → 0.2.0

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: d81f96d9c3c1fb868731f75e2d018280de13d85e
4
- data.tar.gz: d424e2465fa6a905a3b418595591798a22fc229d
3
+ metadata.gz: 795515e4a0541b3666b88ebfc14b0c9d0320bd24
4
+ data.tar.gz: bd901ecbbeefa64aeb9923c85ed1544f0acd6288
5
5
  SHA512:
6
- metadata.gz: a698b14be7efc40420829673334874e2a55ec5d4e969981daa86cef29add8956fa85906b8321b61d755be4564489ee6a66ed0cfced95edfc6e4a8e480fd232e9
7
- data.tar.gz: 83394b6bb177bfc61d6800df8edc9f14d5ca9e7d6f2f1043af711aa6018beed58317da8ca60aa1964686cac6f308f73eef6f3b3d26cf42161a27d9d7cee6f15a
6
+ metadata.gz: 0ce4d22046993fd651aac252a325255663cb7b7b70f845e1609063b6f0a18778d0c2a6126859c5eca7c03ab59f85ee1f2f9b44156c9d3e520a548237562e092c
7
+ data.tar.gz: aab0bd815df76b7c154448bd77236f3e61861417697a9e2dfe040f4865fc0454b86855d73dd32d2e9af20f40cf30be2d2873bf7530c189d4a3c2446a3a78abf6
data/.travis.yml CHANGED
@@ -1,5 +1,5 @@
1
1
  sudo: false
2
- language: ruby
3
2
  rvm:
4
3
  - 2.4.0
5
- before_install: gem install bundler -v 1.13.7
4
+ notifications:
5
+ email: false
@@ -44,14 +44,14 @@ module Webflow
44
44
  post("/collections/#{collection_id}/items", fields: data)
45
45
  end
46
46
 
47
- def update_item(collection_id, item, data)
47
+ def update_item(item, data)
48
48
  # FIXME: (PS) looks like the API does not have partial updates...
49
49
  base = item.reject {|key, _| ['_id', 'published-by', 'published-on', 'created-on', 'created-by', 'updated-by', 'updated-on', '_cid'].include?(key) }
50
- put("/collections/#{collection_id}/items/#{item['_id']}", fields: base.merge(data))
50
+ put("/collections/#{item['_cid']}/items/#{item['_id']}", fields: base.merge(data))
51
51
  end
52
52
 
53
- def delete_item(collection_id, item_id)
54
- delete("/collections/#{collection_id}/items/#{item_id}")
53
+ def delete_item(item)
54
+ delete("/collections/#{item['_cid']}/items/#{item['_id']}")
55
55
  end
56
56
 
57
57
  private
@@ -1,3 +1,3 @@
1
1
  module Webflow
2
- VERSION = "0.1.1"
2
+ VERSION = "0.2.0"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: webflow-ruby
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.1
4
+ version: 0.2.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - phoet
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2017-03-15 00:00:00.000000000 Z
11
+ date: 2017-03-16 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: typhoeus