{"action":"created","comment":{"url":"https://api.github.com/repos/backdrop/backdrop/pulls/comments/52807716","id":52807716,"diff_hunk":"@@ -405,8 +732,36 @@ function path_entity_update(Entity $entity) {\n     $langcode = isset($entity->langcode) ? $entity->langcode : LANGUAGE_NONE;\n     $uri = $entity->uri();\n     $path = $entity->path;\n+    $path_original = $entity->original->path;\n     $path['source'] = $uri['path'];\n \n+    //save a redirect if the path is changed on node save.","path":"core/modules/path/path.module","position":371,"original_position":371,"commit_id":"68ed666b4ffc043bdd040c93db8b31cb5d983883","original_commit_id":"68ed666b4ffc043bdd040c93db8b31cb5d983883","user":{"login":"quicksketch","id":100206,"avatar_url":"https://avatars.githubusercontent.com/u/100206?v=3","gravatar_id":"","url":"https://api.github.com/users/quicksketch","html_url":"https://github.com/quicksketch","followers_url":"https://api.github.com/users/quicksketch/followers","following_url":"https://api.github.com/users/quicksketch/following{/other_user}","gists_url":"https://api.github.com/users/quicksketch/gists{/gist_id}","starred_url":"https://api.github.com/users/quicksketch/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/quicksketch/subscriptions","organizations_url":"https://api.github.com/users/quicksketch/orgs","repos_url":"https://api.github.com/users/quicksketch/repos","events_url":"https://api.github.com/users/quicksketch/events{/privacy}","received_events_url":"https://api.github.com/users/quicksketch/received_events","type":"User","site_admin":false},"body":"This applies to more than just nodes. And some minor formatting. Fix to:\r\n\r\n`// Save a redirect if the path is changed.`","created_at":"2016-02-12T22:33:49Z","updated_at":"2016-02-12T22:33:49Z","html_url":"https://github.com/backdrop/backdrop/pull/1249#discussion_r52807716","pull_request_url":"https://api.github.com/repos/backdrop/backdrop/pulls/1249","_links":{"self":{"href":"https://api.github.com/repos/backdrop/backdrop/pulls/comments/52807716"},"html":{"href":"https://github.com/backdrop/backdrop/pull/1249#discussion_r52807716"},"pull_request":{"href":"https://api.github.com/repos/backdrop/backdrop/pulls/1249"}}},"pull_request":{"url":"https://api.github.com/repos/backdrop/backdrop/pulls/1249","id":58983057,"html_url":"https://github.com/backdrop/backdrop/pull/1249","diff_url":"https://github.com/backdrop/backdrop/pull/1249.diff","patch_url":"https://github.com/backdrop/backdrop/pull/1249.patch","issue_url":"https://api.github.com/repos/backdrop/backdrop/issues/1249","number":1249,"state":"open","locked":false,"title":"Issue #905: Add redirect functionallity to the path module.","user":{"login":"serundeputy","id":6763671,"avatar_url":"https://avatars.githubusercontent.com/u/6763671?v=3","gravatar_id":"","url":"https://api.github.com/users/serundeputy","html_url":"https://github.com/serundeputy","followers_url":"https://api.github.com/users/serundeputy/followers","following_url":"https://api.github.com/users/serundeputy/following{/other_user}","gists_url":"https://api.github.com/users/serundeputy/gists{/gist_id}","starred_url":"https://api.github.com/users/serundeputy/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/serundeputy/subscriptions","organizations_url":"https://api.github.com/users/serundeputy/orgs","repos_url":"https://api.github.com/users/serundeputy/repos","events_url":"https://api.github.com/users/serundeputy/events{/privacy}","received_events_url":"https://api.github.com/users/serundeputy/received_events","type":"User","site_admin":false},"body":"This gets the integration of the redirect module working with nodes.\r\n\r\nI actually only tested `Basic Page`\r\n\r\nhttps://github.com/backdrop/backdrop-issues/issues/905","created_at":"2016-02-11T01:48:24Z","updated_at":"2016-02-12T22:33:49Z","closed_at":null,"merged_at":null,"merge_commit_sha":"00fa00fd45c1cd4bbd2c9d6cb7eae6a97c984d2d","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/backdrop/backdrop/pulls/1249/commits","review_comments_url":"https://api.github.com/repos/backdrop/backdrop/pulls/1249/comments","review_comment_url":"https://api.github.com/repos/backdrop/backdrop/pulls/comments{/number}","comments_url":"https://api.github.com/repos/backdrop/backdrop/issues/1249/comments","statuses_url":"https://api.github.com/repos/backdrop/backdrop/statuses/68ed666b4ffc043bdd040c93db8b31cb5d983883","head":{"label":"serundeputy:905/add_redirect_functionality_to_core","ref":"905/add_redirect_functionality_to_core","sha":"68ed666b4ffc043bdd040c93db8b31cb5d983883","user":{"login":"serundeputy","id":6763671,"avatar_url":"https://avatars.githubusercontent.com/u/6763671?v=3","gravatar_id":"","url":"https://api.github.com/users/serundeputy","html_url":"https://github.com/serundeputy","followers_url":"https://api.github.com/users/serundeputy/followers","following_url":"https://api.github.com/users/serundeputy/following{/other_user}","gists_url":"https://api.github.com/users/serundeputy/gists{/gist_id}","starred_url":"https://api.github.com/users/serundeputy/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/serundeputy/subscriptions","organizations_url":"https://api.github.com/users/serundeputy/orgs","repos_url":"https://api.github.com/users/serundeputy/repos","events_url":"https://api.github.com/users/serundeputy/events{/privacy}","received_events_url":"https://api.github.com/users/serundeputy/received_events","type":"User","site_admin":false},"repo":{"id":29399498,"name":"backdrop","full_name":"serundeputy/backdrop","owner":{"login":"serundeputy","id":6763671,"avatar_url":"https://avatars.githubusercontent.com/u/6763671?v=3","gravatar_id":"","url":"https://api.github.com/users/serundeputy","html_url":"https://github.com/serundeputy","followers_url":"https://api.github.com/users/serundeputy/followers","following_url":"https://api.github.com/users/serundeputy/following{/other_user}","gists_url":"https://api.github.com/users/serundeputy/gists{/gist_id}","starred_url":"https://api.github.com/users/serundeputy/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/serundeputy/subscriptions","organizations_url":"https://api.github.com/users/serundeputy/orgs","repos_url":"https://api.github.com/users/serundeputy/repos","events_url":"https://api.github.com/users/serundeputy/events{/privacy}","received_events_url":"https://api.github.com/users/serundeputy/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/serundeputy/backdrop","description":"Backdrop core code repository.","fork":true,"url":"https://api.github.com/repos/serundeputy/backdrop","forks_url":"https://api.github.com/repos/serundeputy/backdrop/forks","keys_url":"https://api.github.com/repos/serundeputy/backdrop/keys{/key_id}","collaborators_url":"https://api.github.com/repos/serundeputy/backdrop/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/serundeputy/backdrop/teams","hooks_url":"https://api.github.com/repos/serundeputy/backdrop/hooks","issue_events_url":"https://api.github.com/repos/serundeputy/backdrop/issues/events{/number}","events_url":"https://api.github.com/repos/serundeputy/backdrop/events","assignees_url":"https://api.github.com/repos/serundeputy/backdrop/assignees{/user}","branches_url":"https://api.github.com/repos/serundeputy/backdrop/branches{/branch}","tags_url":"https://api.github.com/repos/serundeputy/backdrop/tags","blobs_url":"https://api.github.com/repos/serundeputy/backdrop/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/serundeputy/backdrop/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/serundeputy/backdrop/git/refs{/sha}","trees_url":"https://api.github.com/repos/serundeputy/backdrop/git/trees{/sha}","statuses_url":"https://api.github.com/repos/serundeputy/backdrop/statuses/{sha}","languages_url":"https://api.github.com/repos/serundeputy/backdrop/languages","stargazers_url":"https://api.github.com/repos/serundeputy/backdrop/stargazers","contributors_url":"https://api.github.com/repos/serundeputy/backdrop/contributors","subscribers_url":"https://api.github.com/repos/serundeputy/backdrop/subscribers","subscription_url":"https://api.github.com/repos/serundeputy/backdrop/subscription","commits_url":"https://api.github.com/repos/serundeputy/backdrop/commits{/sha}","git_commits_url":"https://api.github.com/repos/serundeputy/backdrop/git/commits{/sha}","comments_url":"https://api.github.com/repos/serundeputy/backdrop/comments{/number}","issue_comment_url":"https://api.github.com/repos/serundeputy/backdrop/issues/comments{/number}","contents_url":"https://api.github.com/repos/serundeputy/backdrop/contents/{+path}","compare_url":"https://api.github.com/repos/serundeputy/backdrop/compare/{base}...{head}","merges_url":"https://api.github.com/repos/serundeputy/backdrop/merges","archive_url":"https://api.github.com/repos/serundeputy/backdrop/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/serundeputy/backdrop/downloads","issues_url":"https://api.github.com/repos/serundeputy/backdrop/issues{/number}","pulls_url":"https://api.github.com/repos/serundeputy/backdrop/pulls{/number}","milestones_url":"https://api.github.com/repos/serundeputy/backdrop/milestones{/number}","notifications_url":"https://api.github.com/repos/serundeputy/backdrop/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/serundeputy/backdrop/labels{/name}","releases_url":"https://api.github.com/repos/serundeputy/backdrop/releases{/id}","deployments_url":"https://api.github.com/repos/serundeputy/backdrop/deployments","created_at":"2015-01-17T17:38:49Z","updated_at":"2016-01-14T00:35:12Z","pushed_at":"2016-02-11T01:54:57Z","git_url":"git://github.com/serundeputy/backdrop.git","ssh_url":"git@github.com:serundeputy/backdrop.git","clone_url":"https://github.com/serundeputy/backdrop.git","svn_url":"https://github.com/serundeputy/backdrop","homepage":"","size":49744,"stargazers_count":0,"watchers_count":0,"language":"PHP","has_issues":false,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"1.x"}},"base":{"label":"backdrop:1.x","ref":"1.x","sha":"3dd7244a8efc59a14afc2f355e484e4f459b508f","user":{"login":"backdrop","id":5283039,"avatar_url":"https://avatars.githubusercontent.com/u/5283039?v=3","gravatar_id":"","url":"https://api.github.com/users/backdrop","html_url":"https://github.com/backdrop","followers_url":"https://api.github.com/users/backdrop/followers","following_url":"https://api.github.com/users/backdrop/following{/other_user}","gists_url":"https://api.github.com/users/backdrop/gists{/gist_id}","starred_url":"https://api.github.com/users/backdrop/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/backdrop/subscriptions","organizations_url":"https://api.github.com/users/backdrop/orgs","repos_url":"https://api.github.com/users/backdrop/repos","events_url":"https://api.github.com/users/backdrop/events{/privacy}","received_events_url":"https://api.github.com/users/backdrop/received_events","type":"Organization","site_admin":false},"repo":{"id":12285928,"name":"backdrop","full_name":"backdrop/backdrop","owner":{"login":"backdrop","id":5283039,"avatar_url":"https://avatars.githubusercontent.com/u/5283039?v=3","gravatar_id":"","url":"https://api.github.com/users/backdrop","html_url":"https://github.com/backdrop","followers_url":"https://api.github.com/users/backdrop/followers","following_url":"https://api.github.com/users/backdrop/following{/other_user}","gists_url":"https://api.github.com/users/backdrop/gists{/gist_id}","starred_url":"https://api.github.com/users/backdrop/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/backdrop/subscriptions","organizations_url":"https://api.github.com/users/backdrop/orgs","repos_url":"https://api.github.com/users/backdrop/repos","events_url":"https://api.github.com/users/backdrop/events{/privacy}","received_events_url":"https://api.github.com/users/backdrop/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/backdrop/backdrop","description":"Backdrop core code repository.","fork":false,"url":"https://api.github.com/repos/backdrop/backdrop","forks_url":"https://api.github.com/repos/backdrop/backdrop/forks","keys_url":"https://api.github.com/repos/backdrop/backdrop/keys{/key_id}","collaborators_url":"https://api.github.com/repos/backdrop/backdrop/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/backdrop/backdrop/teams","hooks_url":"https://api.github.com/repos/backdrop/backdrop/hooks","issue_events_url":"https://api.github.com/repos/backdrop/backdrop/issues/events{/number}","events_url":"https://api.github.com/repos/backdrop/backdrop/events","assignees_url":"https://api.github.com/repos/backdrop/backdrop/assignees{/user}","branches_url":"https://api.github.com/repos/backdrop/backdrop/branches{/branch}","tags_url":"https://api.github.com/repos/backdrop/backdrop/tags","blobs_url":"https://api.github.com/repos/backdrop/backdrop/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/backdrop/backdrop/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/backdrop/backdrop/git/refs{/sha}","trees_url":"https://api.github.com/repos/backdrop/backdrop/git/trees{/sha}","statuses_url":"https://api.github.com/repos/backdrop/backdrop/statuses/{sha}","languages_url":"https://api.github.com/repos/backdrop/backdrop/languages","stargazers_url":"https://api.github.com/repos/backdrop/backdrop/stargazers","contributors_url":"https://api.github.com/repos/backdrop/backdrop/contributors","subscribers_url":"https://api.github.com/repos/backdrop/backdrop/subscribers","subscription_url":"https://api.github.com/repos/backdrop/backdrop/subscription","commits_url":"https://api.github.com/repos/backdrop/backdrop/commits{/sha}","git_commits_url":"https://api.github.com/repos/backdrop/backdrop/git/commits{/sha}","comments_url":"https://api.github.com/repos/backdrop/backdrop/comments{/number}","issue_comment_url":"https://api.github.com/repos/backdrop/backdrop/issues/comments{/number}","contents_url":"https://api.github.com/repos/backdrop/backdrop/contents/{+path}","compare_url":"https://api.github.com/repos/backdrop/backdrop/compare/{base}...{head}","merges_url":"https://api.github.com/repos/backdrop/backdrop/merges","archive_url":"https://api.github.com/repos/backdrop/backdrop/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/backdrop/backdrop/downloads","issues_url":"https://api.github.com/repos/backdrop/backdrop/issues{/number}","pulls_url":"https://api.github.com/repos/backdrop/backdrop/pulls{/number}","milestones_url":"https://api.github.com/repos/backdrop/backdrop/milestones{/number}","notifications_url":"https://api.github.com/repos/backdrop/backdrop/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/backdrop/backdrop/labels{/name}","releases_url":"https://api.github.com/repos/backdrop/backdrop/releases{/id}","deployments_url":"https://api.github.com/repos/backdrop/backdrop/deployments","created_at":"2013-08-22T01:50:58Z","updated_at":"2016-02-10T04:10:33Z","pushed_at":"2016-02-12T05:51:48Z","git_url":"git://github.com/backdrop/backdrop.git","ssh_url":"git@github.com:backdrop/backdrop.git","clone_url":"https://github.com/backdrop/backdrop.git","svn_url":"https://github.com/backdrop/backdrop","homepage":"","size":53232,"stargazers_count":550,"watchers_count":550,"language":"PHP","has_issues":false,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":192,"mirror_url":null,"open_issues_count":93,"forks":192,"open_issues":93,"watchers":550,"default_branch":"1.x"}},"_links":{"self":{"href":"https://api.github.com/repos/backdrop/backdrop/pulls/1249"},"html":{"href":"https://github.com/backdrop/backdrop/pull/1249"},"issue":{"href":"https://api.github.com/repos/backdrop/backdrop/issues/1249"},"comments":{"href":"https://api.github.com/repos/backdrop/backdrop/issues/1249/comments"},"review_comments":{"href":"https://api.github.com/repos/backdrop/backdrop/pulls/1249/comments"},"review_comment":{"href":"https://api.github.com/repos/backdrop/backdrop/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/backdrop/backdrop/pulls/1249/commits"},"statuses":{"href":"https://api.github.com/repos/backdrop/backdrop/statuses/68ed666b4ffc043bdd040c93db8b31cb5d983883"}}}}