Flowdock
method

schema_up_to_date?

Importance_0
v7.1.3.2 - Show latest stable - 0 notes - Class: DatabaseTasks
schema_up_to_date?(configuration, format = ActiveRecord.schema_format, file = nil) public

No documentation

This method has no description. You can help the Ruby on Rails community by adding new notes.

Hide source
# File activerecord/lib/active_record/tasks/database_tasks.rb, line 370
      def schema_up_to_date?(configuration, format = ActiveRecord.schema_format, file = nil)
        db_config = resolve_configuration(configuration)

        file ||= schema_dump_path(db_config)

        return true unless file && File.exist?(file)

        with_temporary_connection(db_config) do |connection|
          return false unless connection.internal_metadata.enabled?
          return false unless connection.internal_metadata.table_exists?

          connection.internal_metadata[:schema_sha1] == schema_sha1(file)
        end
      end
Register or log in to add new notes.