{"action":"created","comment":{"url":"https://api.github.com/repos/Kinto/formbuilder/pulls/comments/49749349","id":49749349,"diff_hunk":"@@ -62,24 +102,19 @@ export default class EditableField extends Component {\n   }\n \n   handleDrop(data) {\n-    const {name} = this.props;\n+    const {name, swapFields, insertField} = this.props;\n     if (\"moved-field\" in data && data[\"moved-field\"]) {\n       if (data[\"moved-field\"] !== name) {\n-        this.props.swapFields(data[\"moved-field\"], name);\n+        swapFields(data[\"moved-field\"], name);\n       }\n     } else if (\"field\" in data && data.field) {\n-      this.props.insertField(JSON.parse(data.field), name);\n+      insertField(JSON.parse(data.field), name);","path":"formbuilder/components/EditableField.js","position":72,"original_position":72,"commit_id":"831127e0a7fa7e1506650fe6c382d91d47653dcf","original_commit_id":"831127e0a7fa7e1506650fe6c382d91d47653dcf","user":{"login":"almet","id":67073,"avatar_url":"https://avatars.githubusercontent.com/u/67073?v=3","gravatar_id":"","url":"https://api.github.com/users/almet","html_url":"https://github.com/almet","followers_url":"https://api.github.com/users/almet/followers","following_url":"https://api.github.com/users/almet/following{/other_user}","gists_url":"https://api.github.com/users/almet/gists{/gist_id}","starred_url":"https://api.github.com/users/almet/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/almet/subscriptions","organizations_url":"https://api.github.com/users/almet/orgs","repos_url":"https://api.github.com/users/almet/repos","events_url":"https://api.github.com/users/almet/events{/privacy}","received_events_url":"https://api.github.com/users/almet/received_events","type":"User","site_admin":false},"body":"Hmm, why are we JSON parsing here?","created_at":"2016-01-14T16:38:19Z","updated_at":"2016-01-14T16:38:19Z","html_url":"https://github.com/Kinto/formbuilder/pull/3#discussion_r49749349","pull_request_url":"https://api.github.com/repos/Kinto/formbuilder/pulls/3","_links":{"self":{"href":"https://api.github.com/repos/Kinto/formbuilder/pulls/comments/49749349"},"html":{"href":"https://github.com/Kinto/formbuilder/pull/3#discussion_r49749349"},"pull_request":{"href":"https://api.github.com/repos/Kinto/formbuilder/pulls/3"}}},"pull_request":{"url":"https://api.github.com/repos/Kinto/formbuilder/pulls/3","id":56026243,"html_url":"https://github.com/Kinto/formbuilder/pull/3","diff_url":"https://github.com/Kinto/formbuilder/pull/3.diff","patch_url":"https://github.com/Kinto/formbuilder/pull/3.patch","issue_url":"https://api.github.com/repos/Kinto/formbuilder/issues/3","number":3,"state":"open","locked":false,"title":"Fieldset presets.","user":{"login":"n1k0","id":41547,"avatar_url":"https://avatars.githubusercontent.com/u/41547?v=3","gravatar_id":"","url":"https://api.github.com/users/n1k0","html_url":"https://github.com/n1k0","followers_url":"https://api.github.com/users/n1k0/followers","following_url":"https://api.github.com/users/n1k0/following{/other_user}","gists_url":"https://api.github.com/users/n1k0/gists{/gist_id}","starred_url":"https://api.github.com/users/n1k0/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/n1k0/subscriptions","organizations_url":"https://api.github.com/users/n1k0/orgs","repos_url":"https://api.github.com/users/n1k0/repos","events_url":"https://api.github.com/users/n1k0/events{/privacy}","received_events_url":"https://api.github.com/users/n1k0/received_events","type":"User","site_admin":false},"body":"Final r=? @almet","created_at":"2016-01-14T12:00:36Z","updated_at":"2016-01-14T16:38:19Z","closed_at":null,"merged_at":null,"merge_commit_sha":"33a0206220e6f7a00af76dd7ec2573bfca667b74","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/Kinto/formbuilder/pulls/3/commits","review_comments_url":"https://api.github.com/repos/Kinto/formbuilder/pulls/3/comments","review_comment_url":"https://api.github.com/repos/Kinto/formbuilder/pulls/comments{/number}","comments_url":"https://api.github.com/repos/Kinto/formbuilder/issues/3/comments","statuses_url":"https://api.github.com/repos/Kinto/formbuilder/statuses/831127e0a7fa7e1506650fe6c382d91d47653dcf","head":{"label":"Kinto:field-presets","ref":"field-presets","sha":"831127e0a7fa7e1506650fe6c382d91d47653dcf","user":{"login":"Kinto","id":13413813,"avatar_url":"https://avatars.githubusercontent.com/u/13413813?v=3","gravatar_id":"","url":"https://api.github.com/users/Kinto","html_url":"https://github.com/Kinto","followers_url":"https://api.github.com/users/Kinto/followers","following_url":"https://api.github.com/users/Kinto/following{/other_user}","gists_url":"https://api.github.com/users/Kinto/gists{/gist_id}","starred_url":"https://api.github.com/users/Kinto/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Kinto/subscriptions","organizations_url":"https://api.github.com/users/Kinto/orgs","repos_url":"https://api.github.com/users/Kinto/repos","events_url":"https://api.github.com/users/Kinto/events{/privacy}","received_events_url":"https://api.github.com/users/Kinto/received_events","type":"Organization","site_admin":false},"repo":{"id":49138639,"name":"formbuilder","full_name":"Kinto/formbuilder","owner":{"login":"Kinto","id":13413813,"avatar_url":"https://avatars.githubusercontent.com/u/13413813?v=3","gravatar_id":"","url":"https://api.github.com/users/Kinto","html_url":"https://github.com/Kinto","followers_url":"https://api.github.com/users/Kinto/followers","following_url":"https://api.github.com/users/Kinto/following{/other_user}","gists_url":"https://api.github.com/users/Kinto/gists{/gist_id}","starred_url":"https://api.github.com/users/Kinto/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Kinto/subscriptions","organizations_url":"https://api.github.com/users/Kinto/orgs","repos_url":"https://api.github.com/users/Kinto/repos","events_url":"https://api.github.com/users/Kinto/events{/privacy}","received_events_url":"https://api.github.com/users/Kinto/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/Kinto/formbuilder","description":"Yet another Web form editor","fork":false,"url":"https://api.github.com/repos/Kinto/formbuilder","forks_url":"https://api.github.com/repos/Kinto/formbuilder/forks","keys_url":"https://api.github.com/repos/Kinto/formbuilder/keys{/key_id}","collaborators_url":"https://api.github.com/repos/Kinto/formbuilder/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/Kinto/formbuilder/teams","hooks_url":"https://api.github.com/repos/Kinto/formbuilder/hooks","issue_events_url":"https://api.github.com/repos/Kinto/formbuilder/issues/events{/number}","events_url":"https://api.github.com/repos/Kinto/formbuilder/events","assignees_url":"https://api.github.com/repos/Kinto/formbuilder/assignees{/user}","branches_url":"https://api.github.com/repos/Kinto/formbuilder/branches{/branch}","tags_url":"https://api.github.com/repos/Kinto/formbuilder/tags","blobs_url":"https://api.github.com/repos/Kinto/formbuilder/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/Kinto/formbuilder/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/Kinto/formbuilder/git/refs{/sha}","trees_url":"https://api.github.com/repos/Kinto/formbuilder/git/trees{/sha}","statuses_url":"https://api.github.com/repos/Kinto/formbuilder/statuses/{sha}","languages_url":"https://api.github.com/repos/Kinto/formbuilder/languages","stargazers_url":"https://api.github.com/repos/Kinto/formbuilder/stargazers","contributors_url":"https://api.github.com/repos/Kinto/formbuilder/contributors","subscribers_url":"https://api.github.com/repos/Kinto/formbuilder/subscribers","subscription_url":"https://api.github.com/repos/Kinto/formbuilder/subscription","commits_url":"https://api.github.com/repos/Kinto/formbuilder/commits{/sha}","git_commits_url":"https://api.github.com/repos/Kinto/formbuilder/git/commits{/sha}","comments_url":"https://api.github.com/repos/Kinto/formbuilder/comments{/number}","issue_comment_url":"https://api.github.com/repos/Kinto/formbuilder/issues/comments{/number}","contents_url":"https://api.github.com/repos/Kinto/formbuilder/contents/{+path}","compare_url":"https://api.github.com/repos/Kinto/formbuilder/compare/{base}...{head}","merges_url":"https://api.github.com/repos/Kinto/formbuilder/merges","archive_url":"https://api.github.com/repos/Kinto/formbuilder/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/Kinto/formbuilder/downloads","issues_url":"https://api.github.com/repos/Kinto/formbuilder/issues{/number}","pulls_url":"https://api.github.com/repos/Kinto/formbuilder/pulls{/number}","milestones_url":"https://api.github.com/repos/Kinto/formbuilder/milestones{/number}","notifications_url":"https://api.github.com/repos/Kinto/formbuilder/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/Kinto/formbuilder/labels{/name}","releases_url":"https://api.github.com/repos/Kinto/formbuilder/releases{/id}","created_at":"2016-01-06T14:03:15Z","updated_at":"2016-01-11T12:59:34Z","pushed_at":"2016-01-14T16:01:33Z","git_url":"git://github.com/Kinto/formbuilder.git","ssh_url":"git@github.com:Kinto/formbuilder.git","clone_url":"https://github.com/Kinto/formbuilder.git","svn_url":"https://github.com/Kinto/formbuilder","homepage":"https://kinto.github.io/formbuilder/","size":228,"stargazers_count":1,"watchers_count":1,"language":"JavaScript","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":true,"forks_count":1,"mirror_url":null,"open_issues_count":1,"forks":1,"open_issues":1,"watchers":1,"default_branch":"master"}},"base":{"label":"Kinto:master","ref":"master","sha":"4dba3ac4c7ee8fc77f6eeb18dbb4948c18c8a633","user":{"login":"Kinto","id":13413813,"avatar_url":"https://avatars.githubusercontent.com/u/13413813?v=3","gravatar_id":"","url":"https://api.github.com/users/Kinto","html_url":"https://github.com/Kinto","followers_url":"https://api.github.com/users/Kinto/followers","following_url":"https://api.github.com/users/Kinto/following{/other_user}","gists_url":"https://api.github.com/users/Kinto/gists{/gist_id}","starred_url":"https://api.github.com/users/Kinto/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Kinto/subscriptions","organizations_url":"https://api.github.com/users/Kinto/orgs","repos_url":"https://api.github.com/users/Kinto/repos","events_url":"https://api.github.com/users/Kinto/events{/privacy}","received_events_url":"https://api.github.com/users/Kinto/received_events","type":"Organization","site_admin":false},"repo":{"id":49138639,"name":"formbuilder","full_name":"Kinto/formbuilder","owner":{"login":"Kinto","id":13413813,"avatar_url":"https://avatars.githubusercontent.com/u/13413813?v=3","gravatar_id":"","url":"https://api.github.com/users/Kinto","html_url":"https://github.com/Kinto","followers_url":"https://api.github.com/users/Kinto/followers","following_url":"https://api.github.com/users/Kinto/following{/other_user}","gists_url":"https://api.github.com/users/Kinto/gists{/gist_id}","starred_url":"https://api.github.com/users/Kinto/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Kinto/subscriptions","organizations_url":"https://api.github.com/users/Kinto/orgs","repos_url":"https://api.github.com/users/Kinto/repos","events_url":"https://api.github.com/users/Kinto/events{/privacy}","received_events_url":"https://api.github.com/users/Kinto/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/Kinto/formbuilder","description":"Yet another Web form editor","fork":false,"url":"https://api.github.com/repos/Kinto/formbuilder","forks_url":"https://api.github.com/repos/Kinto/formbuilder/forks","keys_url":"https://api.github.com/repos/Kinto/formbuilder/keys{/key_id}","collaborators_url":"https://api.github.com/repos/Kinto/formbuilder/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/Kinto/formbuilder/teams","hooks_url":"https://api.github.com/repos/Kinto/formbuilder/hooks","issue_events_url":"https://api.github.com/repos/Kinto/formbuilder/issues/events{/number}","events_url":"https://api.github.com/repos/Kinto/formbuilder/events","assignees_url":"https://api.github.com/repos/Kinto/formbuilder/assignees{/user}","branches_url":"https://api.github.com/repos/Kinto/formbuilder/branches{/branch}","tags_url":"https://api.github.com/repos/Kinto/formbuilder/tags","blobs_url":"https://api.github.com/repos/Kinto/formbuilder/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/Kinto/formbuilder/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/Kinto/formbuilder/git/refs{/sha}","trees_url":"https://api.github.com/repos/Kinto/formbuilder/git/trees{/sha}","statuses_url":"https://api.github.com/repos/Kinto/formbuilder/statuses/{sha}","languages_url":"https://api.github.com/repos/Kinto/formbuilder/languages","stargazers_url":"https://api.github.com/repos/Kinto/formbuilder/stargazers","contributors_url":"https://api.github.com/repos/Kinto/formbuilder/contributors","subscribers_url":"https://api.github.com/repos/Kinto/formbuilder/subscribers","subscription_url":"https://api.github.com/repos/Kinto/formbuilder/subscription","commits_url":"https://api.github.com/repos/Kinto/formbuilder/commits{/sha}","git_commits_url":"https://api.github.com/repos/Kinto/formbuilder/git/commits{/sha}","comments_url":"https://api.github.com/repos/Kinto/formbuilder/comments{/number}","issue_comment_url":"https://api.github.com/repos/Kinto/formbuilder/issues/comments{/number}","contents_url":"https://api.github.com/repos/Kinto/formbuilder/contents/{+path}","compare_url":"https://api.github.com/repos/Kinto/formbuilder/compare/{base}...{head}","merges_url":"https://api.github.com/repos/Kinto/formbuilder/merges","archive_url":"https://api.github.com/repos/Kinto/formbuilder/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/Kinto/formbuilder/downloads","issues_url":"https://api.github.com/repos/Kinto/formbuilder/issues{/number}","pulls_url":"https://api.github.com/repos/Kinto/formbuilder/pulls{/number}","milestones_url":"https://api.github.com/repos/Kinto/formbuilder/milestones{/number}","notifications_url":"https://api.github.com/repos/Kinto/formbuilder/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/Kinto/formbuilder/labels{/name}","releases_url":"https://api.github.com/repos/Kinto/formbuilder/releases{/id}","created_at":"2016-01-06T14:03:15Z","updated_at":"2016-01-11T12:59:34Z","pushed_at":"2016-01-14T16:01:33Z","git_url":"git://github.com/Kinto/formbuilder.git","ssh_url":"git@github.com:Kinto/formbuilder.git","clone_url":"https://github.com/Kinto/formbuilder.git","svn_url":"https://github.com/Kinto/formbuilder","homepage":"https://kinto.github.io/formbuilder/","size":228,"stargazers_count":1,"watchers_count":1,"language":"JavaScript","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":true,"forks_count":1,"mirror_url":null,"open_issues_count":1,"forks":1,"open_issues":1,"watchers":1,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/Kinto/formbuilder/pulls/3"},"html":{"href":"https://github.com/Kinto/formbuilder/pull/3"},"issue":{"href":"https://api.github.com/repos/Kinto/formbuilder/issues/3"},"comments":{"href":"https://api.github.com/repos/Kinto/formbuilder/issues/3/comments"},"review_comments":{"href":"https://api.github.com/repos/Kinto/formbuilder/pulls/3/comments"},"review_comment":{"href":"https://api.github.com/repos/Kinto/formbuilder/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/Kinto/formbuilder/pulls/3/commits"},"statuses":{"href":"https://api.github.com/repos/Kinto/formbuilder/statuses/831127e0a7fa7e1506650fe6c382d91d47653dcf"}}}}