qoobaa / s3

Library for accessing S3 objects and buckets, supports EU and US buckets
MIT License
258 stars 112 forks source link

Invalid url generated when content type like 'image/jpeg; charset=ISO-8859-1' #28

Closed wereHamster closed 13 years ago

wereHamster commented 13 years ago

The problem is how you extract the file extension: content_type.split('/').last, which in this case returns 'jpeg; charset=ISO-8859-1'. Rails does not accept that as part of the url: ActionView::TemplateError "bad URI(is not URI?): /bucket/file.jpeg; charset=ISO-8859-1"

qoobaa commented 13 years ago

Could you try to find the code that causes the error? S3 does not extract any extensions from content_type - I can't find the code that you mention.

wereHamster commented 13 years ago

I'm sorry. I'm still learning our codebase, and that particular method is indeed part of our application and not the s3 gem.