rest-firebase 1.0.2 → 1.0.3
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 +4 -4
- data/CHANGES.md +21 -0
- data/README.md +2 -1
- data/Rakefile +1 -1
- data/lib/rest-firebase.rb +1 -1
- data/rest-firebase.gemspec +4 -4
- data/task/gemgem.rb +5 -0
- data/test/test_api.rb +7 -0
- metadata +3 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 8b3abd41266838b60199410b6ac1bc94cba83482
|
4
|
+
data.tar.gz: 2b94610d3db1ca7149613ce7f0c475ffc1595270
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 80d3b15e2c4a5540d421643df0c98837b89cc79d523aed558f7edfeb4723d7c449c98e5085943818a0aa84f1e825dc4bbb8d0793c159a603d2d87e07685c9d4e
|
7
|
+
data.tar.gz: fab331037d2b0a0e7470ecb4e3bfb10c7c1f97895ed0522740874516076e82a0564b1c34ac0f5d1cf5f2cc7a78614fb58f0a6ece49ff902af50b7eb32cc790a4
|
data/CHANGES.md
CHANGED
@@ -1,5 +1,26 @@
|
|
1
1
|
# CHANGES
|
2
2
|
|
3
|
+
## rest-firebase 1.0.3 -- 2015-11-16
|
4
|
+
|
5
|
+
### Bugs fixed
|
6
|
+
|
7
|
+
* Raise the default `max_redirects` from 1 to 5 because Firebase introduced
|
8
|
+
an extra redirect for EventSource. 2 is enough in theory but to make it
|
9
|
+
more future compatible, we set the default to 5 for now. If Firebase
|
10
|
+
really needs more than 5 redirects, you could also workaround this by
|
11
|
+
setting `max_redirects` to another number while setting up the client.
|
12
|
+
For example:
|
13
|
+
|
14
|
+
``` ruby
|
15
|
+
client = RestFirebase.new(:max_redirects => 10)
|
16
|
+
# or
|
17
|
+
client = RestFirebase.new
|
18
|
+
client.max_redirects = 10
|
19
|
+
```
|
20
|
+
|
21
|
+
This works for any version of rest-firebase. Thanks @chanibarin
|
22
|
+
See: <https://github.com/CodementorIO/rest-firebase/pull/7>
|
23
|
+
|
3
24
|
## rest-firebase 1.0.2 -- 2015-06-12
|
4
25
|
|
5
26
|
* Fixed a bug where it would try to encode JSON twice upon retrying.
|
data/README.md
CHANGED
@@ -1,4 +1,4 @@
|
|
1
|
-
# rest-firebase [](http://travis-ci.org/CodementorIO/rest-firebase) [](https://coveralls.io/r/CodementorIO/rest-firebase)
|
1
|
+
# rest-firebase [](http://travis-ci.org/CodementorIO/rest-firebase) [](https://coveralls.io/r/CodementorIO/rest-firebase) [](https://gitter.im/CodementorIO/rest-firebase)
|
2
2
|
|
3
3
|
by [Codementor][]
|
4
4
|
|
@@ -211,6 +211,7 @@ If you're using unicorn, you probably want to put that in the config.
|
|
211
211
|
## CONTRIBUTORS:
|
212
212
|
|
213
213
|
* Lin Jen-Shin (@godfat)
|
214
|
+
* Yoshihiro Ibayashi (@chanibarin)
|
214
215
|
|
215
216
|
## LICENSE:
|
216
217
|
|
data/Rakefile
CHANGED
@@ -10,7 +10,7 @@ $LOAD_PATH.unshift(File.expand_path("#{dir}/rest-core/lib"))
|
|
10
10
|
|
11
11
|
Gemgem.init(dir) do |s|
|
12
12
|
s.name = 'rest-firebase'
|
13
|
-
s.version = '1.0.
|
13
|
+
s.version = '1.0.3'
|
14
14
|
s.homepage = 'https://github.com/CodementorIO/rest-firebase'
|
15
15
|
|
16
16
|
s.authors = ['Codementor', 'Lin Jen-Shin (godfat)']
|
data/lib/rest-firebase.rb
CHANGED
@@ -13,7 +13,7 @@ RestFirebase = RC::Builder.client(:d, :secret, :auth, :auth_ttl, :iat) do
|
|
13
13
|
|
14
14
|
use RC::Retry , 0, RC::Retry::DefaultRetryExceptions
|
15
15
|
use RC::Timeout , 10
|
16
|
-
use RC::FollowRedirect,
|
16
|
+
use RC::FollowRedirect, 5
|
17
17
|
use RC::ErrorHandler , lambda{ |env| RestFirebase::Error.call(env) }
|
18
18
|
use RC::ErrorDetectorHttp
|
19
19
|
use RC::JsonResponse , true
|
data/rest-firebase.gemspec
CHANGED
@@ -1,16 +1,16 @@
|
|
1
1
|
# -*- encoding: utf-8 -*-
|
2
|
-
# stub: rest-firebase 1.0.
|
2
|
+
# stub: rest-firebase 1.0.3 ruby lib
|
3
3
|
|
4
4
|
Gem::Specification.new do |s|
|
5
5
|
s.name = "rest-firebase"
|
6
|
-
s.version = "1.0.
|
6
|
+
s.version = "1.0.3"
|
7
7
|
|
8
8
|
s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
|
9
9
|
s.require_paths = ["lib"]
|
10
10
|
s.authors = [
|
11
11
|
"Codementor",
|
12
12
|
"Lin Jen-Shin (godfat)"]
|
13
|
-
s.date = "2015-
|
13
|
+
s.date = "2015-11-16"
|
14
14
|
s.description = "Ruby Firebase REST API client built on top of [rest-core][].\n\n[rest-core]: https://github.com/godfat/rest-core"
|
15
15
|
s.email = ["help@codementor.io"]
|
16
16
|
s.files = [
|
@@ -32,7 +32,7 @@ Gem::Specification.new do |s|
|
|
32
32
|
"test/test_api.rb"]
|
33
33
|
s.homepage = "https://github.com/CodementorIO/rest-firebase"
|
34
34
|
s.licenses = ["Apache License 2.0"]
|
35
|
-
s.rubygems_version = "2.
|
35
|
+
s.rubygems_version = "2.5.0"
|
36
36
|
s.summary = "Ruby Firebase REST API client built on top of [rest-core][]."
|
37
37
|
s.test_files = ["test/test_api.rb"]
|
38
38
|
|
data/task/gemgem.rb
CHANGED
data/test/test_api.rb
CHANGED
@@ -26,6 +26,13 @@ Pork::API.describe RestFirebase do
|
|
26
26
|
firebase.get('https://a').should.eq true
|
27
27
|
end
|
28
28
|
|
29
|
+
would 'get true with callback' do
|
30
|
+
stub_request(:get, path).to_return(:body => 'true')
|
31
|
+
firebase.get('https://a') do |r|
|
32
|
+
r.should.eq true
|
33
|
+
end.wait
|
34
|
+
end
|
35
|
+
|
29
36
|
would 'get with query' do
|
30
37
|
stub_request(:get, "#{path}&orderBy=%22date%22&limitToFirst=1").
|
31
38
|
to_return(:body => json)
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: rest-firebase
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.0.
|
4
|
+
version: 1.0.3
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Codementor
|
@@ -9,7 +9,7 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date: 2015-
|
12
|
+
date: 2015-11-16 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: rest-core
|
@@ -71,7 +71,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
71
71
|
version: '0'
|
72
72
|
requirements: []
|
73
73
|
rubyforge_project:
|
74
|
-
rubygems_version: 2.
|
74
|
+
rubygems_version: 2.5.0
|
75
75
|
signing_key:
|
76
76
|
specification_version: 4
|
77
77
|
summary: Ruby Firebase REST API client built on top of [rest-core][].
|