mirror of
https://github.com/rails/rails.git
synced 2022-11-09 12:12:34 -05:00
add a migrate class method and delegate to the new instance
This commit is contained in:
parent
43fc814074
commit
3a29cc3412
1 changed files with 4 additions and 1 deletions
|
@ -329,10 +329,13 @@ module ActiveRecord
|
|||
end
|
||||
|
||||
def self.method_missing(name, *args, &block) # :nodoc:
|
||||
self.delegate = self.new
|
||||
(delegate || superclass.delegate).send(name, *args, &block)
|
||||
end
|
||||
|
||||
def self.migrate(direction)
|
||||
new.migrate direction
|
||||
end
|
||||
|
||||
cattr_accessor :verbose
|
||||
|
||||
attr_accessor :name, :version
|
||||
|
|
Loading…
Reference in a new issue