pivotalexperimental / desert

Desert is a component framework for Rails that allows your plugins have a Rails app like directory structure, routes, migrations, and dependencies.
http://desert.rubyforge.org
186 stars 31 forks source link

Migrations down are failing. #4

Closed zquestz closed 8 years ago

zquestz commented 14 years ago

When I do migrations they work, until I try to roll back. I hunted down the bug.

desert-0.5.2/lib/desert/plugin_migrations/2.1/migrator.rb

This line: ActiveRecord::Base.connection.update("DELETE FROM #{sm_table} WHERE version = '#{version}' WHERE plugin_name = '#{current_plugin.name}'")

Should be:

ActiveRecord::Base.connection.update("DELETE FROM #{sm_table} WHERE version = '#{version}' AND plugin_name = '#{current_plugin.name}'")

Now everything works as expected. I would have forked this and sent you my change, but github no longer builds gems =(

natlownes commented 14 years ago

this is fixed in 0.5.3