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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: a9bef7701b48a6df684f8014d9514b6968406860
4
- data.tar.gz: 65b56eae484015cea298b41ff8f8f254db735e4a
3
+ metadata.gz: 3926dca6aabc517fcbc74ca6a5dbb9455b4ba7e2
4
+ data.tar.gz: eea4c39a875a1020dad663edcf77bf96fcac8d1a
5
5
  SHA512:
6
- metadata.gz: 5e35f19510578de13aedbfb4ba552e9de82d3360cc041e4d5a2d5c6fc7aa0e46c6e3c5c9ffc09e4177e3a40adc4db95b08370b518dc8450f5adcf14ff1ca53c8
7
- data.tar.gz: 4fb1df95bd17fd235d75a440f5dc6f508a6696f2f29479b5a64ee8cb498bd9f7489dd72cef3a489b23790487d0cbd72c65baac76c78e7068ac3291fb9d2b3450
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 << {captcha: captcha, iden: identifier} if captcha
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)
@@ -7,7 +7,7 @@ module Redd
7
7
  # @param [String] category A category to save to (if gilded).
8
8
  def save(category = nil)
9
9
  params = {id: fullname}
10
- params << {category: category} if category
10
+ params.merge!(category: category) if category
11
11
  post("/api/save", params)
12
12
  end
13
13
 
@@ -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
- @last_request = Time.now
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
@@ -1,4 +1,4 @@
1
1
  module Redd # rubocop:disable Style/Documentation
2
2
  # The semantic version number.
3
- VERSION = "0.7.6"
3
+ VERSION = "0.7.7"
4
4
  end
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.6
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-27 00:00:00.000000000 Z
11
+ date: 2015-04-30 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler