This repository has been archived by the owner on Jul 13, 2023. It is now read-only.
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
2 changed files
with
52 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
I have the following use case for the new
:s3_headers
can be set as a Proc feature. Given the following modelsWhen I create a new song like this
it fails with
NoMethodError: undefined method 'name' for nil:NilClass
inSong#download_filename
because theartist
association is not set at the time the Proc gets called by Paperclip.In order to fix this, I would like to recommend calling the Proc at a later time. Maybe in the
flush_writes
method?