aboutsummaryrefslogtreecommitdiffstats
path: root/railties/lib/rails/initializable.rb
diff options
context:
space:
mode:
Diffstat (limited to 'railties/lib/rails/initializable.rb')
-rw-r--r--railties/lib/rails/initializable.rb3
1 files changed, 2 insertions, 1 deletions
diff --git a/railties/lib/rails/initializable.rb b/railties/lib/rails/initializable.rb
index d78eab9a75..3866b856b2 100644
--- a/railties/lib/rails/initializable.rb
+++ b/railties/lib/rails/initializable.rb
@@ -42,7 +42,8 @@ module Rails
if initializer.before
index = index_for(initializer.before)
elsif initializer.after
- index = index_for(initializer.after) + 1
+ index = index_for(initializer.after)
+ index += 1 if index
else
index = length
end