diff options
-rw-r--r-- | activesupport/CHANGELOG.md | 4 | ||||
-rw-r--r-- | activesupport/lib/active_support/core_ext/object/itself.rb | 2 |
2 files changed, 3 insertions, 3 deletions
diff --git a/activesupport/CHANGELOG.md b/activesupport/CHANGELOG.md index 72fa6722b5..7514faabb2 100644 --- a/activesupport/CHANGELOG.md +++ b/activesupport/CHANGELOG.md @@ -1,7 +1,7 @@ * Added Object#itself which returns the object itself. Useful when dealing with a chaining scenario, like Active Record scopes: - Event.public_send(state.presence_in?([ :trashed, :drafted ]) || :itself).order(:created_at) - + Event.public_send(state.presence_in([ :trashed, :drafted ]) || :itself).order(:created_at) + *DHH* * `Object#with_options` executes block in merging option context when diff --git a/activesupport/lib/active_support/core_ext/object/itself.rb b/activesupport/lib/active_support/core_ext/object/itself.rb index 3065e956c6..adedc20169 100644 --- a/activesupport/lib/active_support/core_ext/object/itself.rb +++ b/activesupport/lib/active_support/core_ext/object/itself.rb @@ -2,7 +2,7 @@ class Object unless respond_to?(:itself) # TODO: Remove this file when we drop support for Ruby < 2.2 # Returns the object itself. Useful when dealing with a chaining scenario, like Active Record scopes: # - # Event.public_send(state.presence_in?([ :trashed, :drafted ]) || :itself).order(:created_at) + # Event.public_send(state.presence_in([ :trashed, :drafted ]) || :itself).order(:created_at) # # @return Object def itself |