diff options
Diffstat (limited to 'activerecord')
-rw-r--r-- | activerecord/lib/active_record/migration.rb | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/activerecord/lib/active_record/migration.rb b/activerecord/lib/active_record/migration.rb index fa9dc83255..cbdef1dd45 100644 --- a/activerecord/lib/active_record/migration.rb +++ b/activerecord/lib/active_record/migration.rb @@ -350,6 +350,10 @@ module ActiveRecord end end + def pending_migrations + migration_classes.select { |m| m.version > current_version } + end + private def migration_classes migrations = migration_files.inject([]) do |migrations, migration_file| |