fix redefinition of signed_id
Rails method by supporting options as arg
This commit is contained in:
parent
00e640a21d
commit
388ccca263
1 changed files with 2 additions and 2 deletions
|
@ -5,8 +5,8 @@ module BlobSignedIdConcern
|
|||
# We override signed_id to add `expires_in` option to generated hash.
|
||||
# This is a measure to ensure that we never under any circumstance
|
||||
# expose permanent attachment url
|
||||
def signed_id
|
||||
ActiveStorage.verifier.generate(id, purpose: :blob_id, expires_in: Rails.application.config.active_storage.service_urls_expire_in)
|
||||
def signed_id(**options)
|
||||
ActiveStorage.verifier.generate(id, **options, purpose: :blob_id, expires_in: Rails.application.config.active_storage.service_urls_expire_in)
|
||||
end
|
||||
end
|
||||
end
|
||||
|
|
Loading…
Reference in a new issue