A platform for community discussion. Free, open, simple.
DEV: Pass the for_export flag to the before_upload_creation event (#10599)
Roman Rizzi726bae8f0c16
diff --git a/lib/upload_creator.rb b/lib/upload_creator.rbindex b0e041a2387..991c3151772 100644--- a/lib/upload_creator.rb+++ b/lib/upload_creator.rb@@ -128,7 +128,7 @@ class UploadCreatoradd_metadata!return @upload unless @upload.save- DiscourseEvent.trigger(:before_upload_creation, @file, is_image)+ DiscourseEvent.trigger(:before_upload_creation, @file, is_image, @opts[:for_export])# store the file and update its urlFile.open(@file.path) do |f|