funky 0.2.12 → 0.2.13

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
  SHA1:
3
- metadata.gz: 5b9e7b186a308ef63690c433f2ddb60bbcb8fa27
4
- data.tar.gz: eedf7241ecaab8a243db77a2fbeceaaf7820049d
3
+ metadata.gz: 542904cd43b9e75e88011affb0c5a11b5c8a90c5
4
+ data.tar.gz: 4a473d2052b7004b63b179c59fc7ddb0ee0052a3
5
5
  SHA512:
6
- metadata.gz: 21ee4481dd2049a91ea7a18c6e86ca1d5e0c840dfb93e00522b30e3661145aebff2970276a7e1b3011daec293eef47cb97e61888b30bb3b570a97b0cfe33dc58
7
- data.tar.gz: 493e943f7097cfbb4d955a8317add67ce3540351485354d5b28fca529847fd918f993541ad069a2b7858b8bffb3bf7a1e4b2e73b132d9ce4251dd7cfd4b80651
6
+ metadata.gz: bc3738d9fc5dfdf001a039dd419fb9b70231a7d4940a9320fc9f035202c89686f313265a2826df0fd13e42db60f2a1069444ec1ab7ba1e18fb1500402350e472
7
+ data.tar.gz: 07d3db9a3a46123dab571a28bfa444b2425fc5451db1ab9f202901ec19d9d585fdfc49ea8c9b774b0a23fa4ea8cb47ad2380e9afd61623ec5a410e14d21b070d
@@ -6,6 +6,19 @@ For more information about changelogs, check
6
6
  [Keep a Changelog](http://keepachangelog.com) and
7
7
  [Vandamme](http://tech-angels.github.io/vandamme).
8
8
 
9
+ ## 0.2.13 - 2017/01/25
10
+
11
+ * [BUGFIX] When Facebook responds with a 302 redirect, sometimes an URL
12
+ with a space is returned (e.g., "https://www.facebook.com/KinoToPrzygoda /videos/322742591438587/") that is not URI encoded. This causes URI#parse to raise an InvalidURIError unless the URL is URL encoded.
13
+
14
+
15
+ ## 2017/01/24
16
+
17
+ * [ENHANCEMENT] Use 2.8 of Facebook Graph API (upgrade from 2.6).
18
+ - There were deprecations in v2.8 of the Facebook Graph API as well as
19
+ additions documented in [the changelog](https://developers.facebook.com/docs/apps/changelog).
20
+ - The current API of Funky is not affected.
21
+
9
22
  ## 0.2.12 - 2017/01/19
10
23
 
11
24
  * [ENHANCEMENT] Parse new format of share & comment count in Facebook HTML
@@ -7,7 +7,7 @@ module Funky
7
7
  class API < Base
8
8
  def self.request(id:, fields:)
9
9
  uri = URI::HTTPS.build host: host,
10
- path: "/v2.6/#{id}",
10
+ path: "/v2.8/#{id}",
11
11
  query: "access_token=#{app_id}%7C#{app_secret}&fields=#{fields}"
12
12
  response_for(get_http_request(uri), uri)
13
13
  end
@@ -42,7 +42,7 @@ module Funky
42
42
 
43
43
  def self.create_batch_for(ids, fields)
44
44
  ids.map do |id|
45
- {"method":"GET", "relative_url": "/v2.6/#{id}?fields=#{fields}"}
45
+ {"method":"GET", "relative_url": "/v2.8/#{id}?fields=#{fields}"}
46
46
  end
47
47
  end
48
48
  end
@@ -20,7 +20,7 @@ module Funky
20
20
  http.request request
21
21
  end
22
22
  if response.is_a? Net::HTTPRedirection
23
- request = Net::HTTP::Get.new URI.parse(response.header['location'])
23
+ request = Net::HTTP::Get.new URI.parse(URI.encode(response.header['location']))
24
24
  response = Net::HTTP.start(uri.host, 443, use_ssl: true) do |http|
25
25
  http.request request
26
26
  end
@@ -1,3 +1,3 @@
1
1
  module Funky
2
- VERSION = "0.2.12"
2
+ VERSION = "0.2.13"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: funky
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.12
4
+ version: 0.2.13
5
5
  platform: ruby
6
6
  authors:
7
7
  - Philip Nguyen
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2017-01-19 00:00:00.000000000 Z
11
+ date: 2017-01-25 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler