Skip to content

Commit

Permalink
Merge pull request #2246 from schovi/patch-1
Browse files Browse the repository at this point in the history
Fix #serializable_hash to returns string keys for versions
  • Loading branch information
mshibuya committed Apr 30, 2019
2 parents 3fda5a2 + 4f05fa4 commit 2aaaedf
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/carrierwave/uploader/serialization.rb
Expand Up @@ -7,7 +7,7 @@ module Serialization
extend ActiveSupport::Concern

def serializable_hash(options = nil)
{"url" => url}.merge Hash[versions.map { |name, version| [name, { "url" => version.url }] }]
{"url" => url}.merge Hash[versions.map { |name, version| [name.to_s, { "url" => version.url }] }]
end

def as_json(options=nil)
Expand Down

0 comments on commit 2aaaedf

Please sign in to comment.