{"action":"opened","number":945,"pull_request":{"url":"https://api.github.com/repos/paritytech/substrate/pulls/945","id":224547206,"node_id":"MDExOlB1bGxSZXF1ZXN0MjI0NTQ3MjA2","html_url":"https://github.com/paritytech/substrate/pull/945","diff_url":"https://github.com/paritytech/substrate/pull/945.diff","patch_url":"https://github.com/paritytech/substrate/pull/945.patch","issue_url":"https://api.github.com/repos/paritytech/substrate/issues/945","number":945,"state":"open","locked":false,"title":"mutate returns a value","user":{"login":"guanqun","id":53862,"node_id":"MDQ6VXNlcjUzODYy","avatar_url":"https://avatars0.githubusercontent.com/u/53862?v=4","gravatar_id":"","url":"https://api.github.com/users/guanqun","html_url":"https://github.com/guanqun","followers_url":"https://api.github.com/users/guanqun/followers","following_url":"https://api.github.com/users/guanqun/following{/other_user}","gists_url":"https://api.github.com/users/guanqun/gists{/gist_id}","starred_url":"https://api.github.com/users/guanqun/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/guanqun/subscriptions","organizations_url":"https://api.github.com/users/guanqun/orgs","repos_url":"https://api.github.com/users/guanqun/repos","events_url":"https://api.github.com/users/guanqun/events{/privacy}","received_events_url":"https://api.github.com/users/guanqun/received_events","type":"User","site_admin":false},"body":"This is an attempt to fix #921\r\n\r\nHowever, this doesn't quite follow the exact the requirement in that issue, we could have some discussion here:\r\n\r\n1. Should this also be applied to StorageMap's mutate? In this commit, I converted it too.\r\n2. Because for mutate's FnOnce, we're passing the \"mut ref\" down, so I don't think we should pass another value out, that would be a bit inconvenient, unless we make the signature look like this `FnOnce(Self::Query) -> Self::Query`.\r\n\r\n@gavofyork @snd \r\n\r\n","created_at":"2018-10-21T15:00:50Z","updated_at":"2018-10-21T15:00:50Z","closed_at":null,"merged_at":null,"merge_commit_sha":null,"assignee":null,"assignees":[],"requested_reviewers":[],"requested_teams":[],"labels":[],"milestone":null,"commits_url":"https://api.github.com/repos/paritytech/substrate/pulls/945/commits","review_comments_url":"https://api.github.com/repos/paritytech/substrate/pulls/945/comments","review_comment_url":"https://api.github.com/repos/paritytech/substrate/pulls/comments{/number}","comments_url":"https://api.github.com/repos/paritytech/substrate/issues/945/comments","statuses_url":"https://api.github.com/repos/paritytech/substrate/statuses/44ac1b08eeebe8dc01be007aeff058563b6da71c","head":{"label":"guanqun:return-mutate-value","ref":"return-mutate-value","sha":"44ac1b08eeebe8dc01be007aeff058563b6da71c","user":{"login":"guanqun","id":53862,"node_id":"MDQ6VXNlcjUzODYy","avatar_url":"https://avatars0.githubusercontent.com/u/53862?v=4","gravatar_id":"","url":"https://api.github.com/users/guanqun","html_url":"https://github.com/guanqun","followers_url":"https://api.github.com/users/guanqun/followers","following_url":"https://api.github.com/users/guanqun/following{/other_user}","gists_url":"https://api.github.com/users/guanqun/gists{/gist_id}","starred_url":"https://api.github.com/users/guanqun/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/guanqun/subscriptions","organizations_url":"https://api.github.com/users/guanqun/orgs","repos_url":"https://api.github.com/users/guanqun/repos","events_url":"https://api.github.com/users/guanqun/events{/privacy}","received_events_url":"https://api.github.com/users/guanqun/received_events","type":"User","site_admin":false},"repo":{"id":111937950,"node_id":"MDEwOlJlcG9zaXRvcnkxMTE5Mzc5NTA=","name":"substrate","full_name":"guanqun/substrate","private":false,"owner":{"login":"guanqun","id":53862,"node_id":"MDQ6VXNlcjUzODYy","avatar_url":"https://avatars0.githubusercontent.com/u/53862?v=4","gravatar_id":"","url":"https://api.github.com/users/guanqun","html_url":"https://github.com/guanqun","followers_url":"https://api.github.com/users/guanqun/followers","following_url":"https://api.github.com/users/guanqun/following{/other_user}","gists_url":"https://api.github.com/users/guanqun/gists{/gist_id}","starred_url":"https://api.github.com/users/guanqun/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/guanqun/subscriptions","organizations_url":"https://api.github.com/users/guanqun/orgs","repos_url":"https://api.github.com/users/guanqun/repos","events_url":"https://api.github.com/users/guanqun/events{/privacy}","received_events_url":"https://api.github.com/users/guanqun/received_events","type":"User","site_admin":false},"html_url":"https://github.com/guanqun/substrate","description":"Polkadot Node Implementation","fork":true,"url":"https://api.github.com/repos/guanqun/substrate","forks_url":"https://api.github.com/repos/guanqun/substrate/forks","keys_url":"https://api.github.com/repos/guanqun/substrate/keys{/key_id}","collaborators_url":"https://api.github.com/repos/guanqun/substrate/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/guanqun/substrate/teams","hooks_url":"https://api.github.com/repos/guanqun/substrate/hooks","issue_events_url":"https://api.github.com/repos/guanqun/substrate/issues/events{/number}","events_url":"https://api.github.com/repos/guanqun/substrate/events","assignees_url":"https://api.github.com/repos/guanqun/substrate/assignees{/user}","branches_url":"https://api.github.com/repos/guanqun/substrate/branches{/branch}","tags_url":"https://api.github.com/repos/guanqun/substrate/tags","blobs_url":"https://api.github.com/repos/guanqun/substrate/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/guanqun/substrate/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/guanqun/substrate/git/refs{/sha}","trees_url":"https://api.github.com/repos/guanqun/substrate/git/trees{/sha}","statuses_url":"https://api.github.com/repos/guanqun/substrate/statuses/{sha}","languages_url":"https://api.github.com/repos/guanqun/substrate/languages","stargazers_url":"https://api.github.com/repos/guanqun/substrate/stargazers","contributors_url":"https://api.github.com/repos/guanqun/substrate/contributors","subscribers_url":"https://api.github.com/repos/guanqun/substrate/subscribers","subscription_url":"https://api.github.com/repos/guanqun/substrate/subscription","commits_url":"https://api.github.com/repos/guanqun/substrate/commits{/sha}","git_commits_url":"https://api.github.com/repos/guanqun/substrate/git/commits{/sha}","comments_url":"https://api.github.com/repos/guanqun/substrate/comments{/number}","issue_comment_url":"https://api.github.com/repos/guanqun/substrate/issues/comments{/number}","contents_url":"https://api.github.com/repos/guanqun/substrate/contents/{+path}","compare_url":"https://api.github.com/repos/guanqun/substrate/compare/{base}...{head}","merges_url":"https://api.github.com/repos/guanqun/substrate/merges","archive_url":"https://api.github.com/repos/guanqun/substrate/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/guanqun/substrate/downloads","issues_url":"https://api.github.com/repos/guanqun/substrate/issues{/number}","pulls_url":"https://api.github.com/repos/guanqun/substrate/pulls{/number}","milestones_url":"https://api.github.com/repos/guanqun/substrate/milestones{/number}","notifications_url":"https://api.github.com/repos/guanqun/substrate/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/guanqun/substrate/labels{/name}","releases_url":"https://api.github.com/repos/guanqun/substrate/releases{/id}","deployments_url":"https://api.github.com/repos/guanqun/substrate/deployments","created_at":"2017-11-24T16:32:10Z","updated_at":"2018-10-14T07:45:39Z","pushed_at":"2018-10-21T14:55:29Z","git_url":"git://github.com/guanqun/substrate.git","ssh_url":"git@github.com:guanqun/substrate.git","clone_url":"https://github.com/guanqun/substrate.git","svn_url":"https://github.com/guanqun/substrate","homepage":null,"size":34681,"stargazers_count":0,"watchers_count":0,"language":"Rust","has_issues":false,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"archived":false,"open_issues_count":0,"license":{"key":"other","name":"Other","spdx_id":"NOASSERTION","url":null,"node_id":"MDc6TGljZW5zZTA="},"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"paritytech:master","ref":"master","sha":"67f4be543b896af7073fdec93960b006b11cf14e","user":{"login":"paritytech","id":14176906,"node_id":"MDEyOk9yZ2FuaXphdGlvbjE0MTc2OTA2","avatar_url":"https://avatars2.githubusercontent.com/u/14176906?v=4","gravatar_id":"","url":"https://api.github.com/users/paritytech","html_url":"https://github.com/paritytech","followers_url":"https://api.github.com/users/paritytech/followers","following_url":"https://api.github.com/users/paritytech/following{/other_user}","gists_url":"https://api.github.com/users/paritytech/gists{/gist_id}","starred_url":"https://api.github.com/users/paritytech/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/paritytech/subscriptions","organizations_url":"https://api.github.com/users/paritytech/orgs","repos_url":"https://api.github.com/users/paritytech/repos","events_url":"https://api.github.com/users/paritytech/events{/privacy}","received_events_url":"https://api.github.com/users/paritytech/received_events","type":"Organization","site_admin":false},"repo":{"id":109872620,"node_id":"MDEwOlJlcG9zaXRvcnkxMDk4NzI2MjA=","name":"substrate","full_name":"paritytech/substrate","private":false,"owner":{"login":"paritytech","id":14176906,"node_id":"MDEyOk9yZ2FuaXphdGlvbjE0MTc2OTA2","avatar_url":"https://avatars2.githubusercontent.com/u/14176906?v=4","gravatar_id":"","url":"https://api.github.com/users/paritytech","html_url":"https://github.com/paritytech","followers_url":"https://api.github.com/users/paritytech/followers","following_url":"https://api.github.com/users/paritytech/following{/other_user}","gists_url":"https://api.github.com/users/paritytech/gists{/gist_id}","starred_url":"https://api.github.com/users/paritytech/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/paritytech/subscriptions","organizations_url":"https://api.github.com/users/paritytech/orgs","repos_url":"https://api.github.com/users/paritytech/repos","events_url":"https://api.github.com/users/paritytech/events{/privacy}","received_events_url":"https://api.github.com/users/paritytech/received_events","type":"Organization","site_admin":false},"html_url":"https://github.com/paritytech/substrate","description":"Substrate: The platform for blockchain innovators","fork":false,"url":"https://api.github.com/repos/paritytech/substrate","forks_url":"https://api.github.com/repos/paritytech/substrate/forks","keys_url":"https://api.github.com/repos/paritytech/substrate/keys{/key_id}","collaborators_url":"https://api.github.com/repos/paritytech/substrate/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/paritytech/substrate/teams","hooks_url":"https://api.github.com/repos/paritytech/substrate/hooks","issue_events_url":"https://api.github.com/repos/paritytech/substrate/issues/events{/number}","events_url":"https://api.github.com/repos/paritytech/substrate/events","assignees_url":"https://api.github.com/repos/paritytech/substrate/assignees{/user}","branches_url":"https://api.github.com/repos/paritytech/substrate/branches{/branch}","tags_url":"https://api.github.com/repos/paritytech/substrate/tags","blobs_url":"https://api.github.com/repos/paritytech/substrate/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/paritytech/substrate/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/paritytech/substrate/git/refs{/sha}","trees_url":"https://api.github.com/repos/paritytech/substrate/git/trees{/sha}","statuses_url":"https://api.github.com/repos/paritytech/substrate/statuses/{sha}","languages_url":"https://api.github.com/repos/paritytech/substrate/languages","stargazers_url":"https://api.github.com/repos/paritytech/substrate/stargazers","contributors_url":"https://api.github.com/repos/paritytech/substrate/contributors","subscribers_url":"https://api.github.com/repos/paritytech/substrate/subscribers","subscription_url":"https://api.github.com/repos/paritytech/substrate/subscription","commits_url":"https://api.github.com/repos/paritytech/substrate/commits{/sha}","git_commits_url":"https://api.github.com/repos/paritytech/substrate/git/commits{/sha}","comments_url":"https://api.github.com/repos/paritytech/substrate/comments{/number}","issue_comment_url":"https://api.github.com/repos/paritytech/substrate/issues/comments{/number}","contents_url":"https://api.github.com/repos/paritytech/substrate/contents/{+path}","compare_url":"https://api.github.com/repos/paritytech/substrate/compare/{base}...{head}","merges_url":"https://api.github.com/repos/paritytech/substrate/merges","archive_url":"https://api.github.com/repos/paritytech/substrate/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/paritytech/substrate/downloads","issues_url":"https://api.github.com/repos/paritytech/substrate/issues{/number}","pulls_url":"https://api.github.com/repos/paritytech/substrate/pulls{/number}","milestones_url":"https://api.github.com/repos/paritytech/substrate/milestones{/number}","notifications_url":"https://api.github.com/repos/paritytech/substrate/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/paritytech/substrate/labels{/name}","releases_url":"https://api.github.com/repos/paritytech/substrate/releases{/id}","deployments_url":"https://api.github.com/repos/paritytech/substrate/deployments","created_at":"2017-11-07T18:08:53Z","updated_at":"2018-10-21T11:26:28Z","pushed_at":"2018-10-21T14:44:31Z","git_url":"git://github.com/paritytech/substrate.git","ssh_url":"git@github.com:paritytech/substrate.git","clone_url":"https://github.com/paritytech/substrate.git","svn_url":"https://github.com/paritytech/substrate","homepage":"","size":42930,"stargazers_count":440,"watchers_count":440,"language":"Rust","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":92,"mirror_url":null,"archived":false,"open_issues_count":81,"license":{"key":"other","name":"Other","spdx_id":"NOASSERTION","url":null,"node_id":"MDc6TGljZW5zZTA="},"forks":92,"open_issues":81,"watchers":440,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/paritytech/substrate/pulls/945"},"html":{"href":"https://github.com/paritytech/substrate/pull/945"},"issue":{"href":"https://api.github.com/repos/paritytech/substrate/issues/945"},"comments":{"href":"https://api.github.com/repos/paritytech/substrate/issues/945/comments"},"review_comments":{"href":"https://api.github.com/repos/paritytech/substrate/pulls/945/comments"},"review_comment":{"href":"https://api.github.com/repos/paritytech/substrate/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/paritytech/substrate/pulls/945/commits"},"statuses":{"href":"https://api.github.com/repos/paritytech/substrate/statuses/44ac1b08eeebe8dc01be007aeff058563b6da71c"}},"author_association":"CONTRIBUTOR","merged":false,"mergeable":null,"rebaseable":null,"mergeable_state":"unknown","merged_by":null,"comments":0,"review_comments":0,"maintainer_can_modify":true,"commits":1,"additions":25,"deletions":15,"changed_files":3}}
{"actor":{"display_login":"guanqun"}}