Skip to content
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 default gravity in MiniMagick resize_and_pad helper #1358

Merged

Conversation

abevoelker
Copy link
Contributor

The default gravity option in the MiniMagick resize_and_pad helper is relying on an RMagick constant. This was causing an error in my uploader (NameError: uninitialized constant Magick) when I wasn't passing in a value for the gravity. Sample class that was giving me the issue:

class ImageUploader < CarrierWave::Uploader::Base
  include CarrierWave::MiniMagick

  version :thumbnail do
    resize_and_pad(160, 160)
  end
end

This probably won't affect many people since the docs specify using process directly.

bensie added a commit that referenced this pull request May 8, 2014
Fix default gravity in MiniMagick resize_and_pad helper
@bensie bensie merged commit 9e2bc6b into carrierwaveuploader:master May 8, 2014
@bensie
Copy link
Member

bensie commented May 8, 2014

Good catch :) Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants