socialfred 1.0.0 → 1.0.1

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.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: bf0f7c212bcfde1137b710b1555eae73ac0fd25a6551d98401820693456576d0
4
- data.tar.gz: eae0c693bcbc04d4ba0d92914c5bfb8662194932435aea0b64a6118a42660a51
3
+ metadata.gz: 7f11030d6f2232279f9c201c4b8fc2296e5e93a56f5559ec087e11cfadeff614
4
+ data.tar.gz: e626c0dedae80f84e81b3c0fdb6695374caf2b112d7e1c7bb82acaa5c43e65ba
5
5
  SHA512:
6
- metadata.gz: e15d2266d35b8eff226eecfb951ec306a21ba7715abeab6838fa46778eaa5d59f1c65b0456fb7ceb3f003f22034b365c2d7c4d678a3a4d8f76c9c62e87296ba2
7
- data.tar.gz: 4060f94ec07eb8fa953442dc76e12157afa1977c8d87ac76c0a58f5818c3e591ee343a6ca8a6c4421a591b064583f5413ee8afd7fb8ccf543c14ebeda9d252f0
6
+ metadata.gz: ddd5aa659171f8698aae7dd5f99f606b94eaac8390733d384ea869dc7f9c721f13a87b9ac30969f9b71b5276262bedad22b4e1c2f5d2293a6921f1b5dcf94087
7
+ data.tar.gz: 66fa6643ddab3068a02a485014c5abfa6abf51e41057110fe8257a603e3c8a080225d78dd90155e962962f665b1e11f3c643c50064094ea1d0e847205baa8743
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- socialfred (1.0.0)
4
+ socialfred (1.0.1)
5
5
  faraday (>= 0.9.0)
6
6
  json (~> 2.2)
7
7
 
@@ -17,7 +17,7 @@ module Socialfred
17
17
  def all(page: 1, per_page: 10)
18
18
  response = requester.get(ENDPOINT, page: page, per_page: per_page)
19
19
 
20
- raise Socialfred::Error unless response.status == 200
20
+ raise Socialfred::Error, response.body unless response.status == 200
21
21
 
22
22
  JSON.parse(response.body)
23
23
  end
@@ -25,7 +25,7 @@ module Socialfred
25
25
  def find(publication_id)
26
26
  response = requester.get(ENDPOINT + "/#{publication_id}")
27
27
 
28
- raise Socialfred::Error unless response.status == 200
28
+ raise Socialfred::Error, response.body unless response.status == 200
29
29
 
30
30
  JSON.parse(response.body)
31
31
  end
@@ -49,7 +49,7 @@ module Socialfred
49
49
  parameters = { publication: { published_at: publish_at, text: text, images: images, options: options }.compact }
50
50
  response = requester.put(ENDPOINT + "/#{publication_id}", parameters)
51
51
 
52
- raise Socialfred::Error unless response.status == 200
52
+ raise Socialfred::Error, response.body unless response.status == 200
53
53
 
54
54
  JSON.parse(response.body)
55
55
  end
@@ -57,7 +57,7 @@ module Socialfred
57
57
  def destroy(publication_id)
58
58
  response = requester.delete(ENDPOINT + "/#{publication_id}")
59
59
 
60
- raise Socialfred::Error unless response.status == 200
60
+ raise Socialfred::Error, response.body unless response.status == 200
61
61
 
62
62
  JSON.parse(response.body)
63
63
  end
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module Socialfred
4
- VERSION = '1.0.0'
4
+ VERSION = '1.0.1'
5
5
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: socialfred
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.0
4
+ version: 1.0.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Alexey Krasnoperov