Reputation: 4016
An app uses paperclip to handle file uploads for user avatars.
Paperclip currently deletes old files when new ones are files, however, I wish for the users to see a history of what they have uploaded.
Is there a way to prevent paperclip from deleting old files when new files are uploaded?
Thank you in advance,
Upvotes: 2
Views: 628
Reputation: 124419
has_attached_file
has a :keep_old_files
options you can set. For example:
has_attached_file :avatar, :keep_old_files => true
Source: http://rubydoc.info/gems/paperclip/Paperclip/ClassMethods:has_attached_file
Upvotes: 4