mirror of
https://github.com/discourse/discourse.git
synced 2024-12-15 20:16:17 +08:00
b72cec188a
Follow up to df1e6eed5a
.
17 lines
378 B
Ruby
17 lines
378 B
Ruby
# frozen_string_literal: true
|
|
|
|
Fabricator(:optimized_image) do
|
|
upload
|
|
sha1 "86f7e437faa5a7fce15d1ddcb9eaeaea377667b8"
|
|
extension ".png"
|
|
width 100
|
|
height 200
|
|
version OptimizedImage::VERSION
|
|
|
|
after_build do |optimized_image, _|
|
|
unless optimized_image.url
|
|
optimized_image.url = Discourse.store.get_path_for_optimized_image(optimized_image)
|
|
end
|
|
end
|
|
end
|