mirror of
https://github.com/discourse/discourse.git
synced 2024-12-02 13:39:36 -06:00
2f7a307237
It's possible in Rails to map a single route to multiple controller actions with different constraints. We do this in at least 1 place in our application for the root route (/) to make it possible to change the page that root route displays. This means that if you get the list of routes of your application, you'll get the same route for each time the route is defined. And if there's an API scope for 2 (or more) controller actions that map to the same route, the route will be listed twice in the Allowed URLs list of the scope. To prevent this, this PR adds the allowed URLs in a set so that duplicate routes are automatically removed. |
||
---|---|---|
.. | ||
assets | ||
controllers | ||
helpers | ||
jobs | ||
mailers | ||
models | ||
serializers | ||
services | ||
views |