Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

MiniMagick - cannot load such file

I'm trying to use MiniMagick to resize images and I did the following in my controller file:

require 'rubygems'
require 'mini_magick'

and

img = MiniMagick::Image.open(file)

But when I invoke the controller the following

LoadError (cannot load such file -- mini_magick)

I've added gem 'mini_magick' to my Gemfile so I have really no idea what's going on. Can someone help me with this?

BTW, it is available in both irb and rails console, but not when run as a server.

Thx in advance.

like image 203
Guanlun Avatar asked Apr 19 '13 15:04

Guanlun


1 Answers

Dammit, restarting the server solved it..

like image 160
Guanlun Avatar answered Sep 23 '22 20:09

Guanlun