New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix removing files on update #169

Merged
merged 1 commit into from Mar 25, 2014

Conversation

Projects
None yet
2 participants
@janko-m
Contributor

janko-m commented Feb 11, 2014

During updating, if the #remove_<column> was assigned, then carrierwave_backgrounder would prevent deletion of that photo (that is, it would prevent assigning the column to a blank value).

Fix removing files on update
During updating, if the `#remove_<column>` was assigned, then
carrierwave_backgrounder would prevent deletion of that photo.

carrierwave_backgrounder doesn't have the functionality of deleting
files in the background (nor should it, this is a very cheap operation).
But it prevents the removal of the file, as if it's going to do it
in the background. Here we put put that, if the file is scheduled for
removal, delegate to the regular foreground process (by assigning the
`process_<column>_upload` attribute).
@janko-m

This comment has been minimized.

Show comment
Hide comment
@janko-m

janko-m Feb 13, 2014

Contributor

I updated the solution, it now sets process_<column>_upload to true when the file has been marked for deletion. It feels right now :)

Contributor

janko-m commented Feb 13, 2014

I updated the solution, it now sets process_<column>_upload to true when the file has been marked for deletion. It feels right now :)

lardawge added a commit that referenced this pull request Mar 25, 2014

@lardawge lardawge merged commit dab2e6d into lardawge:master Mar 25, 2014

1 check passed

default The Travis CI build passed
Details

@janko-m janko-m deleted the janko-m:remove-file branch Jul 27, 2014

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment