Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

ActiveRecord::Core#initialize: improve performance

  • Loading branch information...
commit 791251bf8b95debf2c3af61f1b675a30d1abf3fd 1 parent 29094c0
@bogdan bogdan authored
Showing with 1 addition and 1 deletion.
  1. +1 −1  activerecord/lib/active_record/core.rb
View
2  activerecord/lib/active_record/core.rb
@@ -176,7 +176,7 @@ def initialize(attributes = nil, options = {})
assign_attributes(attributes, options) if attributes
yield self if block_given?
- run_callbacks :initialize
+ run_callbacks :initialize if _initialize_callbacks.any?
end
# Initialize an empty model object from +coder+. +coder+ must contain
Please sign in to comment.
Something went wrong with that request. Please try again.