Commit message (Collapse) | Author | Age | Files | Lines | |
---|---|---|---|---|---|
* | Pure rack apps can be mounted with a name | Jean Boussier | 2014-11-29 | 1 | -7/+1 |
| | | | | See https://github.com/rails/rails/commit/9b15828b5c347395b42066a588c88e5eb4e72279#commitcomment-8764492 | ||||
* | Refactor nested if | Bruno Sutic | 2014-11-26 | 1 | -5/+3 |
| | |||||
* | Wrap code snippets in +, not backticks, in sdoc | claudiob | 2014-11-20 | 1 | -3/+3 |
| | | | | [ci skip] | ||||
* | edit pass over all warnings | Xavier Noria | 2014-10-28 | 1 | -2/+11 |
| | | | | | | | | | | | | | | | This patch uniformizes warning messages. I used the most common style already present in the code base: * Capitalize the first word. * End the message with a full stop. * "Rails 5" instead of "Rails 5.0". * Backticks for method names and inline code. Also, converted a few long strings into the new heredoc convention. | ||||
* | Fix typo in actionpack/lib/action_dispatch/routing/mapper.rb | Yuutetu | 2014-10-16 | 1 | -1/+1 |
| | |||||
* | Don't ignore constraints in redirect routes | Agis- | 2014-08-25 | 1 | -2/+0 |
| | | | | | | | | https://github.com/rails/rails/commit/402c2af55053c2f29319091ad21fd6fa6b90ee89 introduced a regression that caused any constraints added to redirect routes to be ignored. Fixes #16605 | ||||
* | ask the scope object if it is a resource_method_scope | Aaron Patterson | 2014-08-13 | 1 | -10/+13 |
| | |||||
* | ask the scope for the action name | Aaron Patterson | 2014-08-13 | 1 | -14/+18 |
| | |||||
* | reduce calls to scope_level | Aaron Patterson | 2014-08-13 | 1 | -1/+5 |
| | | | | | this will help us to encapsulate magical symbols so hopefully we can eliminate hardcoded magic symbols | ||||
* | change to attr_reader | Aaron Patterson | 2014-08-13 | 1 | -5/+1 |
| | |||||
* | scope_level is no longer a hash key, just use the ivar | Aaron Patterson | 2014-08-13 | 1 | -4/+9 |
| | |||||
* | move the scope level key fully inside the scope object | Aaron Patterson | 2014-08-13 | 1 | -1/+5 |
| | |||||
* | move scope_level to a method on the scope object | Aaron Patterson | 2014-08-13 | 1 | -7/+20 |
| | | | | now we don't have to have a hard coded key | ||||
* | only look up scope level once | Aaron Patterson | 2014-08-13 | 1 | -6/+7 |
| | | | | avoid hash lookups and remove depency on the instance | ||||
* | only test `prefix` once | Aaron Patterson | 2014-08-13 | 1 | -2/+4 |
| | | | | we don't need to repeat if statements | ||||
* | pass consistent parameters to canonical_action? | Aaron Patterson | 2014-08-13 | 1 | -5/+5 |
| | | | | | now we only have to look up @scope[:scope_level] once per call to canonical_action? and we don't have a variable named "flag" | ||||
* | fewer operations on the options hash | Aaron Patterson | 2014-08-13 | 1 | -10/+10 |
| | | | | | since we pass `as` down, then we won't have to do an insert / delete dance with the options hash | ||||
* | always return a string from find_script_name | Aaron Patterson | 2014-08-01 | 1 | -5/+7 |
| | | | | this allows us to avoid nil checks on the return value | ||||
* | use `get` instead of accessing the named routes internals | Aaron Patterson | 2014-07-31 | 1 | -1/+1 |
| | |||||
* | invert check so we fail faster | Aaron Patterson | 2014-07-31 | 1 | -1/+1 |
| | | | | | there's no reason to to_sym the string if it doesn't match the regexp anyway | ||||
* | do a hash lookup for collision detection | Aaron Patterson | 2014-07-31 | 1 | -1/+1 |
| | | | | hash lookup should be faster than searching an array. | ||||
* | push options inside the scope object | Aaron Patterson | 2014-07-30 | 1 | -4/+9 |
| | |||||
* | turn scope in to a linked list | Aaron Patterson | 2014-07-30 | 1 | -15/+36 |
| | | | | this makes scope rollback much easier | ||||
* | remove the mounted? method | Aaron Patterson | 2014-07-28 | 1 | -1/+1 |
| | | | | | we know the routes should not be "optimized" when mounting an application | ||||
* | push rails app testing up | Aaron Patterson | 2014-07-16 | 1 | -9/+13 |
| | | | | this way we only have to test for whether it is a rails app once. | ||||
* | Rails-ish apps should descend from Rails::Railtie | Aaron Patterson | 2014-07-16 | 1 | -8/+3 |
| | | | | | Use an is_a check to ensure it's a Railsish app so we can avoid respond_to calls everywhere. | ||||
* | app should always be a class (I suppose) | Aaron Patterson | 2014-07-16 | 1 | -1/+1 |
| | |||||
* | we should be checking if the app is a class | Aaron Patterson | 2014-07-16 | 1 | -1/+1 |
| | | | | | Hopefully `object.class` always returns something that is_a?(Class), so the previous logic didn't really make sense. | ||||
* | routed applications will respond to these methods | Aaron Patterson | 2014-07-15 | 1 | -1/+1 |
| | |||||
* | RouteSet should be in charge of constructing the dispather | Aaron Patterson | 2014-07-15 | 1 | -8/+9 |
| | | | | Now we can override how requests are dispatched in the routeset object | ||||
* | Generate shallow paths for all children of shallow resources. | Seb Jacobs | 2014-07-06 | 1 | -1/+1 |
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Prior to this commit shallow resources would only generate paths for non-direct children (with a nested depth greater than 1). Take the following routes file. resources :blogs do resources :posts, shallow: true do resources :comments do resources :tags end end end This would generate shallow paths for `tags` nested under `posts`, e.g `/posts/:id/tags/`, however it would not generate shallow paths for `comments` nested under `posts`, e.g `/posts/:id/comments/new`. This commit changes the behaviour of the route mapper so that it generate paths for direct children of shallow resources, for example if you take the previous routes file, this will now generate shallow paths for `comments` nested under `posts`, .e.g `posts/:id/comments/new`. This was the behaviour in Rails `4.0.4` however this was broken in @jcoglan's fix for another routes related issue[1]. This also fixes an issue[2] reported by @smdern. [1] https://github.com/rails/rails/commit/d0e5963 [2] https://github.com/rails/rails/issues/15783 | ||||
* | Fix doc unwanted dl Admin:: [ci skip] | Ciro Santilli | 2014-07-01 | 1 | -1/+1 |
| | |||||
* | push splitting "to" up the callstack | Aaron Patterson | 2014-06-03 | 1 | -15/+20 |
| | |||||
* | Routes specifying 'to:' must be a string that contains a "#" or a rack | Aaron Patterson | 2014-06-03 | 1 | -3/+21 |
| | | | | | application. Use of a symbol should be replaced with `action: symbol`. Use of a string without a "#" should be replaced with `controller: string`. | ||||
* | push some options munging to an alternate constructor | Aaron Patterson | 2014-06-03 | 1 | -13/+19 |
| | |||||
* | move options_constraints tests next to each other | Aaron Patterson | 2014-06-03 | 1 | -2/+2 |
| | |||||
* | only do is_a checks on `formatted` once | Aaron Patterson | 2014-06-03 | 1 | -9/+5 |
| | |||||
* | push options_constraints processing up | Aaron Patterson | 2014-06-03 | 1 | -22/+24 |
| | | | | | this lets us reduce is_a checks on the options_constraints and push "callable constraints" verification to the right place. | ||||
* | remove options as an ivar | Aaron Patterson | 2014-06-03 | 1 | -6/+8 |
| | |||||
* | only do Regexp === option once | Aaron Patterson | 2014-06-03 | 1 | -3/+4 |
| | |||||
* | return early from add_request_method | Aaron Patterson | 2014-06-03 | 1 | -11/+11 |
| | |||||
* | only loop over `options` once (hopefully) | Aaron Patterson | 2014-06-03 | 1 | -13/+11 |
| | |||||
* | only loop through constraints once | Aaron Patterson | 2014-06-03 | 1 | -19/+15 |
| | |||||
* | change defaults allocation to a one-liner | Aaron Patterson | 2014-06-03 | 1 | -3/+2 |
| | |||||
* | no longer need the scope ivar | Aaron Patterson | 2014-06-03 | 1 | -2/+1 |
| | |||||
* | only look up scope[:module] once | Aaron Patterson | 2014-06-03 | 1 | -6/+6 |
| | |||||
* | remove IGNORE_OPTIONS | Aaron Patterson | 2014-06-03 | 1 | -4/+8 |
| | |||||
* | :only is never used in Mapping, so rm the key | Aaron Patterson | 2014-06-03 | 1 | -1/+2 |
| | |||||
* | remove :defaults from the IGNORE_OPTIONS list | Aaron Patterson | 2014-06-03 | 1 | -4/+4 |
| | |||||
* | remove :constraints from IGNORE_OPTIONS | Aaron Patterson | 2014-06-03 | 1 | -4/+5 |
| |