Permalink
Browse files

Fixed order of allowed formats to be sorted.

  • Loading branch information...
jnunemaker committed Jul 19, 2009
1 parent ae3cd0f commit a236fb08af90948bbfb02f012937a3f0cafaffe2
Showing with 1 addition and 1 deletion.
  1. +1 −1 lib/httparty.rb
View
@@ -105,7 +105,7 @@ def cookies(h={})
# format :json
# end
def format(f)
- raise UnsupportedFormat, "Must be one of: #{AllowedFormats.values.map(&:to_s).uniq.sort.join(', ')}" unless AllowedFormats.value?(f)
+ raise UnsupportedFormat, "Must be one of: #{AllowedFormats.values.map { |v| v.to_s }.uniq.sort.join(', ')}" unless AllowedFormats.value?(f)
default_options[:format] = f
end

0 comments on commit a236fb0

Please sign in to comment.