redd 0.7.6 → 0.7.7
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/redd/objects/thing/messageable.rb +1 -1
- data/lib/redd/objects/thing/saveable.rb +1 -1
- data/lib/redd/rate_limit.rb +1 -1
- data/lib/redd/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 3926dca6aabc517fcbc74ca6a5dbb9455b4ba7e2
|
4
|
+
data.tar.gz: eea4c39a875a1020dad663edcf77bf96fcac8d1a
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: f5f649f74ca1fcef2ec2d5bd885cd993a0c85c89b9423cc9eeb77a80cdea56a01735c2e59d4a6e5d94d718ef1ee52240628f5ee749e47e4df750ab32107fef15
|
7
|
+
data.tar.gz: bd87e00808c774e53f60dbba84c6185e875e5c6643d9abb6cf43bbb2854365faa097ff30edab91a0d4a3c6bf3ba15c6cff2f18de33a6bbfce85f84fbcd3d2d87
|
@@ -17,7 +17,7 @@ module Redd
|
|
17
17
|
subject, text, from_sr = nil, captcha = nil, identifier = nil
|
18
18
|
)
|
19
19
|
params = {subject: subject, text: text}
|
20
|
-
params
|
20
|
+
params.merge!(captcha: captcha, iden: identifier) if captcha
|
21
21
|
params[:from_sr] = client.property(from_sr, :display_name) if from_sr
|
22
22
|
params[:to] =
|
23
23
|
if respond_to?(:display_name)
|
data/lib/redd/rate_limit.rb
CHANGED
@@ -62,7 +62,7 @@ module Redd
|
|
62
62
|
# Update necessary info with each request.
|
63
63
|
# @param [Faraday::Response] response The response to the request made.
|
64
64
|
def update!(response)
|
65
|
-
@
|
65
|
+
@last_request_time = Time.now
|
66
66
|
%w(used remaining reset).each do |type|
|
67
67
|
value = response.headers["x-ratelimit-#{type}"]
|
68
68
|
instance_variable_set("@#{type}", value.to_i) unless value.nil?
|
data/lib/redd/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: redd
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.7.
|
4
|
+
version: 0.7.7
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Avinash Dwarapu
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2015-04-
|
11
|
+
date: 2015-04-30 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|