diff options
author | Alberto Almagro <albertoalmagro@gmail.com> | 2018-12-02 18:10:03 +0100 |
---|---|---|
committer | Alberto Almagro <albertoalmagro@gmail.com> | 2018-12-02 18:10:03 +0100 |
commit | c93bad207087ab656b27c559012b5e8eb31ed20d (patch) | |
tree | 111a792d32388db98a306fc7438781e8eda70d93 | |
parent | aa1ba9cb244b1e03d36aaa941ae4e91c6713b77e (diff) | |
download | rails-c93bad207087ab656b27c559012b5e8eb31ed20d.tar.gz rails-c93bad207087ab656b27c559012b5e8eb31ed20d.tar.bz2 rails-c93bad207087ab656b27c559012b5e8eb31ed20d.zip |
Remove unnecessary variable route
The variable `route` was only allocated to hold an object that was
immediately returned. This patch removes that variable.
-rw-r--r-- | actionpack/lib/action_dispatch/routing/mapper.rb | 13 |
1 files changed, 2 insertions, 11 deletions
diff --git a/actionpack/lib/action_dispatch/routing/mapper.rb b/actionpack/lib/action_dispatch/routing/mapper.rb index 421e2023c2..d67044b4ac 100644 --- a/actionpack/lib/action_dispatch/routing/mapper.rb +++ b/actionpack/lib/action_dispatch/routing/mapper.rb @@ -160,17 +160,8 @@ module ActionDispatch end def make_route(name, precedence) - route = Journey::Route.new(name, - application, - path, - conditions, - required_defaults, - defaults, - request_method, - precedence, - @internal) - - route + Journey::Route.new(name, application, path, conditions, required_defaults, + defaults, request_method, precedence, @internal) end def application |