diff options
author | Aaron Patterson <aaron.patterson@gmail.com> | 2010-11-18 15:07:25 -0800 |
---|---|---|
committer | Aaron Patterson <aaron.patterson@gmail.com> | 2010-11-19 10:24:15 -0800 |
commit | 5d93900dc6a423fe8d7b0c6e330deeaca4b8b72c (patch) | |
tree | 632f8f67eb5cac6a5afe73018c366ea2a18ddcb2 /activerecord/lib/active_record/migration | |
parent | 24b637a80f659eb03f8efe459f9d6aae2338e434 (diff) | |
download | rails-5d93900dc6a423fe8d7b0c6e330deeaca4b8b72c.tar.gz rails-5d93900dc6a423fe8d7b0c6e330deeaca4b8b72c.tar.bz2 rails-5d93900dc6a423fe8d7b0c6e330deeaca4b8b72c.zip |
add and remove timestamps can be inverted
Diffstat (limited to 'activerecord/lib/active_record/migration')
-rw-r--r-- | activerecord/lib/active_record/migration/command_recorder.rb | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/activerecord/lib/active_record/migration/command_recorder.rb b/activerecord/lib/active_record/migration/command_recorder.rb index 032ce3aad8..231e981e53 100644 --- a/activerecord/lib/active_record/migration/command_recorder.rb +++ b/activerecord/lib/active_record/migration/command_recorder.rb @@ -48,6 +48,14 @@ module ActiveRecord table, columns, _ = *args [:remove_index, [table, {:column => columns}]] end + + def invert_remove_timestamps(args) + [:add_timestamps, args] + end + + def invert_add_timestamps(args) + [:remove_timestamps, args] + end end end end |