diff options
author | Aaron Patterson <aaron.patterson@gmail.com> | 2012-01-12 15:53:32 -0800 |
---|---|---|
committer | Aaron Patterson <aaron.patterson@gmail.com> | 2012-01-13 14:33:58 -0800 |
commit | f3f8f0eb310bf8384f334c19943f9b15430402ca (patch) | |
tree | c21e87e2b192c67c388e50b5362ca6397ded56ab /activerecord/lib | |
parent | 6c7b66f67b0cda88d788278abd5a38f5c3ac152b (diff) | |
download | rails-f3f8f0eb310bf8384f334c19943f9b15430402ca.tar.gz rails-f3f8f0eb310bf8384f334c19943f9b15430402ca.tar.bz2 rails-f3f8f0eb310bf8384f334c19943f9b15430402ca.zip |
use the schema migration model to create a new record
Diffstat (limited to 'activerecord/lib')
-rw-r--r-- | activerecord/lib/active_record/migration.rb | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/activerecord/lib/active_record/migration.rb b/activerecord/lib/active_record/migration.rb index c000b94bc8..f0def7a265 100644 --- a/activerecord/lib/active_record/migration.rb +++ b/activerecord/lib/active_record/migration.rb @@ -761,8 +761,7 @@ module ActiveRecord Base.connection.delete stmt else @migrated_versions.push(version).sort! - stmt = table.compile_insert table["version"] => version.to_s - Base.connection.insert stmt + ActiveRecord::SchemaMigration.create!(:version => version.to_s) end end |