39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
|
# File 'lib/active_record/connection_adapters/oracle_enhanced_procedures.rb', line 39
def self.included(base)
base.instance_eval do
alias_method_chain :create, :custom_method
if private_instance_methods.include?('update_without_dirty') || private_instance_methods.include?(:update_without_dirty)
alias_method :update_without_custom_method, :update_without_dirty
alias_method :update_without_dirty, :update_with_custom_method
else
alias_method_chain :update, :custom_method
end
private :create, :update
alias_method_chain :destroy, :custom_method
public :destroy
end
end
|