mirror of
https://github.com/LaCasemate/fab-manager.git
synced 2025-01-29 18:52:22 +01:00
fix social sharing of trainings
This commit is contained in:
parent
679ccfec99
commit
c174f22c00
@ -55,4 +55,9 @@ class TrainingImageUploader < CarrierWave::Uploader::Base
|
|||||||
def filename
|
def filename
|
||||||
"training_image.#{file.extension}" if original_filename
|
"training_image.#{file.extension}" if original_filename
|
||||||
end
|
end
|
||||||
|
|
||||||
|
# return an array like [width, height]
|
||||||
|
def dimensions
|
||||||
|
::MiniMagick::Image.open(file.file)[:dimensions]
|
||||||
|
end
|
||||||
end
|
end
|
||||||
|
Loading…
x
Reference in New Issue
Block a user