aboutsummaryrefslogtreecommitdiffstats
path: root/activesupport/lib
diff options
context:
space:
mode:
Diffstat (limited to 'activesupport/lib')
-rw-r--r--activesupport/lib/active_support/string_inquirer.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/activesupport/lib/active_support/string_inquirer.rb b/activesupport/lib/active_support/string_inquirer.rb
index cd722a3cfb..e6b1f39225 100644
--- a/activesupport/lib/active_support/string_inquirer.rb
+++ b/activesupport/lib/active_support/string_inquirer.rb
@@ -11,7 +11,7 @@ module ActiveSupport
#
class StringInquirer < String
def method_missing(method_name, *arguments)
- if method_name.to_s.ends_with?("?")
+ if method_name.to_s[-1,1] == "?"
self == method_name.to_s[0..-2]
else
super