aboutsummaryrefslogtreecommitdiffstats
path: root/activestorage/app/models/active_storage/blob.rb
diff options
context:
space:
mode:
Diffstat (limited to 'activestorage/app/models/active_storage/blob.rb')
-rw-r--r--activestorage/app/models/active_storage/blob.rb4
1 files changed, 2 insertions, 2 deletions
diff --git a/activestorage/app/models/active_storage/blob.rb b/activestorage/app/models/active_storage/blob.rb
index d43049e32c..84b8f3827b 100644
--- a/activestorage/app/models/active_storage/blob.rb
+++ b/activestorage/app/models/active_storage/blob.rb
@@ -124,7 +124,7 @@ class ActiveStorage::Blob < ActiveRecord::Base
# This will create a URL for that specific blob with that specific variant, which the ActiveStorage::VariantsController
# can then produce on-demand.
def variant(transformations)
- ActiveStorage::Variant.new(self, ActiveStorage::Variation.new(transformations))
+ ActiveStorage::Variant.new(self, ActiveStorage::Variation.wrap(transformations))
end
@@ -144,7 +144,7 @@ class ActiveStorage::Blob < ActiveRecord::Base
# whether a blob is accepted by any previewer, call ActiveStorage::Blob#previewable?.
def preview(transformations)
if previewable?
- ActiveStorage::Preview.new(self, ActiveStorage::Variation.new(transformations))
+ ActiveStorage::Preview.new(self, ActiveStorage::Variation.wrap(transformations))
else
raise UnpreviewableError
end