Remove block definition from method, is not needed since yield is used inside.

This commit is contained in:
Emilio Tagua
2010-06-24 12:02:00 -03:00
parent d9f199e123
commit 4086ecea24
3 changed files with 3 additions and 3 deletions

View File

@@ -107,7 +107,7 @@ module ActiveRecord
# REFERENTIAL INTEGRITY ====================================
# Override to turn off referential integrity while executing <tt>&block</tt>.
def disable_referential_integrity(&block)
def disable_referential_integrity
yield
end

View File

@@ -219,7 +219,7 @@ module ActiveRecord
# REFERENTIAL INTEGRITY ====================================
def disable_referential_integrity(&block) #:nodoc:
def disable_referential_integrity #:nodoc:
old = select_value("SELECT @@FOREIGN_KEY_CHECKS")
begin

View File

@@ -372,7 +372,7 @@ module ActiveRecord
return false
end
def disable_referential_integrity(&block) #:nodoc:
def disable_referential_integrity #:nodoc:
if supports_disable_referential_integrity?() then
execute(tables.collect { |name| "ALTER TABLE #{quote_table_name(name)} DISABLE TRIGGER ALL" }.join(";"))
end