lardawge/carrierwave_backgrounder — pull request #122 by snikch (2013-03-15 20:02:38+00:00)
Title: Unsaved records queueing jobs

`after_commit` is fired even if the record is not saved, so activerecord is currently queueing a job when validation fails.

This commit fixes it for AR, but I don't know if the `new_record?` method exists in data mapper, so I cannot promise that it will not break DM support.