omniauth-fitbit 1.0.2 → 1.0.3
Sign up to get free protection for your applications and to get access to all the features.
@@ -8,7 +8,7 @@ module OmniAuth
|
|
8
8
|
option :name, "fitbit"
|
9
9
|
|
10
10
|
option :client_options, {
|
11
|
-
:site => '
|
11
|
+
:site => 'https://api.fitbit.com',
|
12
12
|
:request_token_path => '/oauth/request_token',
|
13
13
|
:access_token_path => '/oauth/access_token',
|
14
14
|
:authorize_path => '/oauth/authorize'
|
@@ -43,8 +43,12 @@ module OmniAuth
|
|
43
43
|
end
|
44
44
|
|
45
45
|
def raw_info
|
46
|
-
|
46
|
+
if options[:use_english_measure] == 'true'
|
47
|
+
@raw_info ||= MultiJson.load(access_token.request('get', 'http://api.fitbit.com/1/user/-/profile.json', { 'Accept-Language' => 'en_US' }).body)
|
48
|
+
else
|
49
|
+
@raw_info ||= MultiJson.load(access_token.get('http://api.fitbit.com/1/user/-/profile.json').body)
|
50
|
+
end
|
47
51
|
end
|
48
52
|
end
|
49
53
|
end
|
50
|
-
end
|
54
|
+
end
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: omniauth-fitbit
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.0.
|
4
|
+
version: 1.0.3
|
5
5
|
prerelease:
|
6
6
|
platform: ruby
|
7
7
|
authors:
|
@@ -9,7 +9,7 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date:
|
12
|
+
date: 2014-01-29 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: omniauth-oauth
|