{"action":"created","issue":{"url":"https://api.github.com/repos/laravel/framework/issues/7432","labels_url":"https://api.github.com/repos/laravel/framework/issues/7432/labels{/name}","comments_url":"https://api.github.com/repos/laravel/framework/issues/7432/comments","events_url":"https://api.github.com/repos/laravel/framework/issues/7432/events","html_url":"https://github.com/laravel/framework/pull/7432","id":57723374,"number":7432,"title":"Route Cache Improvements","user":{"login":"baileylo","id":145345,"avatar_url":"https://avatars.githubusercontent.com/u/145345?v=3","gravatar_id":"","url":"https://api.github.com/users/baileylo","html_url":"https://github.com/baileylo","followers_url":"https://api.github.com/users/baileylo/followers","following_url":"https://api.github.com/users/baileylo/following{/other_user}","gists_url":"https://api.github.com/users/baileylo/gists{/gist_id}","starred_url":"https://api.github.com/users/baileylo/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/baileylo/subscriptions","organizations_url":"https://api.github.com/users/baileylo/orgs","repos_url":"https://api.github.com/users/baileylo/repos","events_url":"https://api.github.com/users/baileylo/events{/privacy}","received_events_url":"https://api.github.com/users/baileylo/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/laravel/framework/labels/requires%20changes","name":"requires changes","color":"fef2c0"}],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":4,"created_at":"2015-02-15T08:51:39Z","updated_at":"2015-02-16T00:30:45Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/laravel/framework/pulls/7432","html_url":"https://github.com/laravel/framework/pull/7432","diff_url":"https://github.com/laravel/framework/pull/7432.diff","patch_url":"https://github.com/laravel/framework/pull/7432.patch"},"body":"# My Issue \r\n\r\nI had two routes with the same URI and method but different names. When I tried to cache the routes the command would fail with a serialization error.\r\n\r\n# Solution\r\n\r\nI dug into the code and figured out that when routes were prepared for serialization only one of the arrays of routes was iterated over. There were other routes in the collection in other arrays that would not be prepare for serialization. Following tell don't ask, rather than asking for all the routes in the collection and prepare the routes for serialization, I added a method to tell the collection to prepare it for serialization.\r\n\r\n# Side Notes\r\n\r\nI feel like this seems rather awkward so I feel I should explain why I have two routes with the same URi and method but with different names. My site is a blog and has both permalink pages as well as blog posts. Both can be access from *.tld/{slug}*. If there was no post that could match `{slug}` then the app would check for a matching page. I wanted to keep the route generation separate for the 2 objects in case I decided to change the uris later. This was the original issue, I found it also applied to action as well as header differences and included a solution that solved all three issues."},"comment":{"url":"https://api.github.com/repos/laravel/framework/issues/comments/74446169","html_url":"https://github.com/laravel/framework/pull/7432#issuecomment-74446169","issue_url":"https://api.github.com/repos/laravel/framework/issues/7432","id":74446169,"user":{"login":"baileylo","id":145345,"avatar_url":"https://avatars.githubusercontent.com/u/145345?v=3","gravatar_id":"","url":"https://api.github.com/users/baileylo","html_url":"https://github.com/baileylo","followers_url":"https://api.github.com/users/baileylo/followers","following_url":"https://api.github.com/users/baileylo/following{/other_user}","gists_url":"https://api.github.com/users/baileylo/gists{/gist_id}","starred_url":"https://api.github.com/users/baileylo/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/baileylo/subscriptions","organizations_url":"https://api.github.com/users/baileylo/orgs","repos_url":"https://api.github.com/users/baileylo/repos","events_url":"https://api.github.com/users/baileylo/events{/privacy}","received_events_url":"https://api.github.com/users/baileylo/received_events","type":"User","site_admin":false},"created_at":"2015-02-16T00:30:45Z","updated_at":"2015-02-16T00:30:45Z","body":"@GrahamCampbell Should the \"requires changes\" tag be removed?"}}