class Doorkeeper::ApplicationScopesGenerator
def self.next_migration_number(path)
def self.next_migration_number(path) ActiveRecord::Generators::Base.next_migration_number(path) end
def application_scopes
def application_scopes if oauth_applications_exists? && !scopes_column_exists? migration_template( 'add_scopes_to_oauth_applications.rb', 'db/migrate/add_scopes_to_oauth_applications.rb' ) end end
def oauth_applications_exists?
def oauth_applications_exists? ActiveRecord::Base.connection.table_exists? :oauth_applications end
def scopes_column_exists?
def scopes_column_exists? ActiveRecord::Base.connection.column_exists?( :oauth_applications, :scopes ) end