diff options
author | Aaron Patterson <aaron.patterson@gmail.com> | 2014-05-25 13:43:14 -0700 |
---|---|---|
committer | Aaron Patterson <aaron.patterson@gmail.com> | 2014-05-25 13:43:14 -0700 |
commit | 8a51ec01581625876904bb785f66aac9788e043d (patch) | |
tree | 648c7b34d0ccd11f64cd5a713908bdc17da2ccde /actionpack | |
parent | b6ec5e2c14e30bbb8a8dc434da36fc976440f2ca (diff) | |
download | rails-8a51ec01581625876904bb785f66aac9788e043d.tar.gz rails-8a51ec01581625876904bb785f66aac9788e043d.tar.bz2 rails-8a51ec01581625876904bb785f66aac9788e043d.zip |
Constraints#app should never return another Constraints object, so switch to if statement
Diffstat (limited to 'actionpack')
-rw-r--r-- | actionpack/lib/action_dispatch/routing/mapper.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/actionpack/lib/action_dispatch/routing/mapper.rb b/actionpack/lib/action_dispatch/routing/mapper.rb index a6f17b9459..9656109ed3 100644 --- a/actionpack/lib/action_dispatch/routing/mapper.rb +++ b/actionpack/lib/action_dispatch/routing/mapper.rb @@ -23,7 +23,7 @@ module ActionDispatch # to pass a Constraints object to this constructor, but there were # multiple places that kept testing children of this object. I # *think* they were just being defensive, but I have no idea. - while app.is_a?(self.class) + if app.is_a?(self.class) constraints += app.constraints app = app.app end |