Permalink
Browse files

Forgot that Aws::S3::Bucket#keys returns an Array of S3::Key objects.

  • Loading branch information...
1 parent 4869f99 commit 201f1f3c855be052f51490338c892818bc937407 @postmodern postmodern committed with solnic Oct 13, 2010
Showing with 1 addition and 1 deletion.
  1. +1 −1 lib/dm-paperclip/storage/s3.rb
@@ -93,7 +93,7 @@ def s3_expiring_url(key,time)
end
def s3_exists?(key)
- @s3_bucket.keys(:prefix => key).include?(key)
+ @s3_bucket.keys(:prefix => key).any? { |s3_key| s3_key.name == key }
end
def s3_download(key,file)

0 comments on commit 201f1f3

Please sign in to comment.