plataformatec/devise — pull request #2192 by nthj (2012-12-29 20:02:12+00:00)
Title: Swallow devise routing errors when re-setting database

I frequently run 'rake db:migrate:reset db:seed' when developing, to get back to my default mock-up state. Unfortunately, Devise assumes that the database table should exist at this point, and throws a SQL error. For example:

PG::Error: ERROR: relation "users" does not exist

Since I'm trying to re-set the database, this is frustrating. I have to comment out the "devise_for" line in my routes.rb, run my migrations, then un-comment the devise_for line again.

This pull request simply swallows any exceptions from devise_for when running db:migrate.