Skip to content

Commit

Permalink
forcing value to string
Browse files Browse the repository at this point in the history
  • Loading branch information
mwmitchell committed Mar 29, 2013
1 parent 9e31617 commit d2b21b2
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/rsolr/client.rb
Original file line number Diff line number Diff line change
Expand Up @@ -190,7 +190,7 @@ def retry_503?(request_context, response)
# Retry-After can be a relative number of seconds from now, or an RFC 1123 Date.
# If the latter, attempt to convert it to a relative time in seconds.
def retry_after(response)
retry_after = Array(response[:headers]['Retry-After'] || response[:headers]['retry-after']).flatten.first
retry_after = Array(response[:headers]['Retry-After'] || response[:headers]['retry-after']).flatten.first.to_s
if retry_after =~ /\A[0-9]+\Z/
retry_after = retry_after.to_i
else
Expand Down

0 comments on commit d2b21b2

Please sign in to comment.