aboutsummaryrefslogtreecommitdiffstats
path: root/activestorage/lib/active_storage/engine.rb
diff options
context:
space:
mode:
Diffstat (limited to 'activestorage/lib/active_storage/engine.rb')
-rw-r--r--activestorage/lib/active_storage/engine.rb4
1 files changed, 3 insertions, 1 deletions
diff --git a/activestorage/lib/active_storage/engine.rb b/activestorage/lib/active_storage/engine.rb
index 89e61163f5..1d345920fa 100644
--- a/activestorage/lib/active_storage/engine.rb
+++ b/activestorage/lib/active_storage/engine.rb
@@ -27,7 +27,9 @@ module ActiveStorage
initializer "active_storage.verifier" do
config.after_initialize do |app|
- ActiveStorage.verifier = app.message_verifier("ActiveStorage")
+ if app.config.secret_key_base.present?
+ ActiveStorage.verifier = app.message_verifier("ActiveStorage")
+ end
end
end