lib/cloudinary/carrier_wave/storage.rb in cloudinary-1.0.41 vs lib/cloudinary/carrier_wave/storage.rb in cloudinary-1.0.42

- old
+ new

@@ -34,11 +34,11 @@ end store_cloudinary_version(uploader.metadata["version"]) if uploader.metadata["version"] # Will throw an exception on error else - raise "nested versions are not allowed." if (uploader.class.version_names.length > 1) + raise CloudinaryException, "nested versions are not allowed." if (uploader.class.version_names.length > 1) # Do nothing - versions are not handled locally. end nil end @@ -55,9 +55,9 @@ uploader.model.set(column, name) elsif model_class.respond_to?(:update_all) && uploader.model.respond_to?(:_id) model_class.where(:_id=>uploader.model._id).update_all(column=>name) uploader.model.send :write_attribute, column, name else - raise "Only ActiveRecord and Mongoid are supported at the moment!" + raise CloudinaryException, "Only ActiveRecord and Mongoid are supported at the moment!" end end end