ohmage 0.0.24 → 0.0.25
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/lib/ohmage/client.rb +10 -0
- data/lib/ohmage/request.rb +1 -1
- data/lib/ohmage/version.rb +1 -1
- 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: 0e3a2baedf8debe18741d488ea0d765a1cad52ad
|
4
|
+
data.tar.gz: f9632b82b6ce590c1bfdecfd93f00113ec53e33a
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 9a57d975d2bb843036eb3c439d6ce391e00d2c16d650282f25e5543fe58d2790064de4adf4fb0a3acaf8dcb0fa345296b253ac35dfbb409ec47451c5c0fbd903
|
7
|
+
data.tar.gz: 539c5be8ea40b193eeffa7fe35ff422ad2e955e8c91149d585d5ebd553d5705eddf63705d0c7c1031a28381a0032db2e9074d8787261b915c5d0e4daf91796b8
|
data/lib/ohmage/client.rb
CHANGED
@@ -45,5 +45,15 @@ module Ohmage
|
|
45
45
|
resp[:token]
|
46
46
|
end
|
47
47
|
alias_method :auth, :auth_token
|
48
|
+
|
49
|
+
# Masking password from inspected client.
|
50
|
+
# Lovingly lifted from https://github.com/octokit/octokit.rb,
|
51
|
+
# The full text of the license for this work (MIT) can be found at
|
52
|
+
# http://opensource.org/licenses/mit
|
53
|
+
# @return [String]
|
54
|
+
def inspect
|
55
|
+
inspected = super
|
56
|
+
inspected.gsub! @password, '*******' if @password
|
57
|
+
end
|
48
58
|
end
|
49
59
|
end
|
data/lib/ohmage/request.rb
CHANGED
@@ -25,7 +25,7 @@ module Ohmage
|
|
25
25
|
def perform # rubocop:disable all
|
26
26
|
response = HTTP.public_send(@request_method, @uri.to_s, @params)
|
27
27
|
# ohmage responds to image/read, audio/read, video/read (and media/read) with a file only.
|
28
|
-
unless
|
28
|
+
unless response.headers['Content-Type'] == 'application/json'
|
29
29
|
return response.body
|
30
30
|
end
|
31
31
|
response_body = symbolize_keys!(response.parse)
|
data/lib/ohmage/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: ohmage
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.25
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Steve Nolen
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2015-
|
11
|
+
date: 2015-12-17 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: addressable
|
@@ -119,7 +119,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
119
119
|
version: 1.3.5
|
120
120
|
requirements: []
|
121
121
|
rubyforge_project:
|
122
|
-
rubygems_version: 2.
|
122
|
+
rubygems_version: 2.4.6
|
123
123
|
signing_key:
|
124
124
|
specification_version: 4
|
125
125
|
summary: A Ruby interface for the ohmage 2.x API.
|