Skip to content

Upgrading Clearance to 0.8.5

croaky edited this page Sep 13, 2010 · 6 revisions

If you have used an older version of Clearance and wish to upgrade your app to version 0.8.5, there are a couple of things you should know. (All examples are from converting a 0.7.0 Clearance gem to

Clean up your system

sudo gem uninstall clearance

Uninstall all versions.

The gem is now on Gemcutter

No surprise obviously, just put this snippet in your config/environment.rb file:

config.gem 'clearance', :version => '0.8.5'

Run generator

As the README states, run the following in console:

script/generate clearance
rake db:migrate

attr_accessible is NO LONGER in the Clearance::User module

Since it has been removed, you can add that line to your existing User model. E.g.,

attr_accessible :email, :password, :password_confirmation

If Clearance is giving you mass assignment errors, this snippet above answers the “why” they are happening.