aboutsummaryrefslogtreecommitdiffstats
path: root/activesupport/lib/active_support/core_ext/string/access.rb
diff options
context:
space:
mode:
Diffstat (limited to 'activesupport/lib/active_support/core_ext/string/access.rb')
-rw-r--r--activesupport/lib/active_support/core_ext/string/access.rb4
1 files changed, 2 insertions, 2 deletions
diff --git a/activesupport/lib/active_support/core_ext/string/access.rb b/activesupport/lib/active_support/core_ext/string/access.rb
index 213a91aa7a..b6afd32fb0 100644
--- a/activesupport/lib/active_support/core_ext/string/access.rb
+++ b/activesupport/lib/active_support/core_ext/string/access.rb
@@ -74,7 +74,7 @@ class String
# str.first(6) # => "hello"
def first(limit = 1)
if limit == 0
- ''
+ ""
elsif limit >= size
self.dup
else
@@ -94,7 +94,7 @@ class String
# str.last(6) # => "hello"
def last(limit = 1)
if limit == 0
- ''
+ ""
elsif limit >= size
self.dup
else