{"action":"created","comment":{"url":"https://api.github.com/repos/mailgun/scroll/pulls/comments/28533727","id":28533727,"diff_hunk":"@@ -26,13 +27,31 @@ func GetStringFieldWithDefault(r *http.Request, fieldName, defaultValue string)\n \treturn defaultValue\n }\n \n+// A multiParamRegex is used to convert Ruby and PHP style array params.\n+// PHP uses [\"param[0]\", \"param[1]\",..] instead of [\"param\", \"param\",..]\n+// Ruby uses [\"param[]\", \"param[]\",..]\n+var multiParamRegex *regexp.Regexp\n+\n+func init() {\n+\tmultiParamRegex = regexp.MustCompile(`^([a-z:]*)\\[[\\d]*\\]$`)","path":"fields.go","position":null,"original_position":18,"commit_id":"e25bbc4924e445ff68082dd6bd66932f1da33b0b","original_commit_id":"eda959e74bbd97497db647c0767dbbd8a1960e8c","user":{"login":"anton-efimenko","id":436387,"avatar_url":"https://avatars.githubusercontent.com/u/436387?v=3","gravatar_id":"","url":"https://api.github.com/users/anton-efimenko","html_url":"https://github.com/anton-efimenko","followers_url":"https://api.github.com/users/anton-efimenko/followers","following_url":"https://api.github.com/users/anton-efimenko/following{/other_user}","gists_url":"https://api.github.com/users/anton-efimenko/gists{/gist_id}","starred_url":"https://api.github.com/users/anton-efimenko/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/anton-efimenko/subscriptions","organizations_url":"https://api.github.com/users/anton-efimenko/orgs","repos_url":"https://api.github.com/users/anton-efimenko/repos","events_url":"https://api.github.com/users/anton-efimenko/events{/privacy}","received_events_url":"https://api.github.com/users/anton-efimenko/received_events","type":"User","site_admin":false},"body":"Fixed.","created_at":"2015-04-16T17:57:32Z","updated_at":"2015-04-16T17:57:32Z","html_url":"https://github.com/mailgun/scroll/pull/26#discussion_r28533727","pull_request_url":"https://api.github.com/repos/mailgun/scroll/pulls/26","_links":{"self":{"href":"https://api.github.com/repos/mailgun/scroll/pulls/comments/28533727"},"html":{"href":"https://github.com/mailgun/scroll/pull/26#discussion_r28533727"},"pull_request":{"href":"https://api.github.com/repos/mailgun/scroll/pulls/26"}}},"pull_request":{"url":"https://api.github.com/repos/mailgun/scroll/pulls/26","id":33422783,"html_url":"https://github.com/mailgun/scroll/pull/26","diff_url":"https://github.com/mailgun/scroll/pull/26.diff","patch_url":"https://github.com/mailgun/scroll/pull/26.patch","issue_url":"https://api.github.com/repos/mailgun/scroll/issues/26","number":26,"state":"open","locked":false,"title":"Add support to PHP and Ruby like multiple fields","user":{"login":"anton-efimenko","id":436387,"avatar_url":"https://avatars.githubusercontent.com/u/436387?v=3","gravatar_id":"","url":"https://api.github.com/users/anton-efimenko","html_url":"https://github.com/anton-efimenko","followers_url":"https://api.github.com/users/anton-efimenko/followers","following_url":"https://api.github.com/users/anton-efimenko/following{/other_user}","gists_url":"https://api.github.com/users/anton-efimenko/gists{/gist_id}","starred_url":"https://api.github.com/users/anton-efimenko/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/anton-efimenko/subscriptions","organizations_url":"https://api.github.com/users/anton-efimenko/orgs","repos_url":"https://api.github.com/users/anton-efimenko/repos","events_url":"https://api.github.com/users/anton-efimenko/events{/privacy}","received_events_url":"https://api.github.com/users/anton-efimenko/received_events","type":"User","site_admin":false},"body":"**Purpose**\r\n\r\nPHP and Ruby frameworks pass multiple parameters as `param[0], param[1]` for PHP and `param[], param[]` for Ruby.","created_at":"2015-04-16T06:40:08Z","updated_at":"2015-04-16T17:57:33Z","closed_at":null,"merged_at":null,"merge_commit_sha":"dc227bc3aef93333563eca86ece241dad8147ed2","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/mailgun/scroll/pulls/26/commits","review_comments_url":"https://api.github.com/repos/mailgun/scroll/pulls/26/comments","review_comment_url":"https://api.github.com/repos/mailgun/scroll/pulls/comments{/number}","comments_url":"https://api.github.com/repos/mailgun/scroll/issues/26/comments","statuses_url":"https://api.github.com/repos/mailgun/scroll/statuses/e25bbc4924e445ff68082dd6bd66932f1da33b0b","head":{"label":"mailgun:anton/multi-fields","ref":"anton/multi-fields","sha":"e25bbc4924e445ff68082dd6bd66932f1da33b0b","user":{"login":"mailgun","id":447686,"avatar_url":"https://avatars.githubusercontent.com/u/447686?v=3","gravatar_id":"","url":"https://api.github.com/users/mailgun","html_url":"https://github.com/mailgun","followers_url":"https://api.github.com/users/mailgun/followers","following_url":"https://api.github.com/users/mailgun/following{/other_user}","gists_url":"https://api.github.com/users/mailgun/gists{/gist_id}","starred_url":"https://api.github.com/users/mailgun/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mailgun/subscriptions","organizations_url":"https://api.github.com/users/mailgun/orgs","repos_url":"https://api.github.com/users/mailgun/repos","events_url":"https://api.github.com/users/mailgun/events{/privacy}","received_events_url":"https://api.github.com/users/mailgun/received_events","type":"Organization","site_admin":false},"repo":{"id":23436353,"name":"scroll","full_name":"mailgun/scroll","owner":{"login":"mailgun","id":447686,"avatar_url":"https://avatars.githubusercontent.com/u/447686?v=3","gravatar_id":"","url":"https://api.github.com/users/mailgun","html_url":"https://github.com/mailgun","followers_url":"https://api.github.com/users/mailgun/followers","following_url":"https://api.github.com/users/mailgun/following{/other_user}","gists_url":"https://api.github.com/users/mailgun/gists{/gist_id}","starred_url":"https://api.github.com/users/mailgun/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mailgun/subscriptions","organizations_url":"https://api.github.com/users/mailgun/orgs","repos_url":"https://api.github.com/users/mailgun/repos","events_url":"https://api.github.com/users/mailgun/events{/privacy}","received_events_url":"https://api.github.com/users/mailgun/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/mailgun/scroll","description":"Scroll is a lightweight library for building Go HTTP services at Mailgun.","fork":false,"url":"https://api.github.com/repos/mailgun/scroll","forks_url":"https://api.github.com/repos/mailgun/scroll/forks","keys_url":"https://api.github.com/repos/mailgun/scroll/keys{/key_id}","collaborators_url":"https://api.github.com/repos/mailgun/scroll/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/mailgun/scroll/teams","hooks_url":"https://api.github.com/repos/mailgun/scroll/hooks","issue_events_url":"https://api.github.com/repos/mailgun/scroll/issues/events{/number}","events_url":"https://api.github.com/repos/mailgun/scroll/events","assignees_url":"https://api.github.com/repos/mailgun/scroll/assignees{/user}","branches_url":"https://api.github.com/repos/mailgun/scroll/branches{/branch}","tags_url":"https://api.github.com/repos/mailgun/scroll/tags","blobs_url":"https://api.github.com/repos/mailgun/scroll/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/mailgun/scroll/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/mailgun/scroll/git/refs{/sha}","trees_url":"https://api.github.com/repos/mailgun/scroll/git/trees{/sha}","statuses_url":"https://api.github.com/repos/mailgun/scroll/statuses/{sha}","languages_url":"https://api.github.com/repos/mailgun/scroll/languages","stargazers_url":"https://api.github.com/repos/mailgun/scroll/stargazers","contributors_url":"https://api.github.com/repos/mailgun/scroll/contributors","subscribers_url":"https://api.github.com/repos/mailgun/scroll/subscribers","subscription_url":"https://api.github.com/repos/mailgun/scroll/subscription","commits_url":"https://api.github.com/repos/mailgun/scroll/commits{/sha}","git_commits_url":"https://api.github.com/repos/mailgun/scroll/git/commits{/sha}","comments_url":"https://api.github.com/repos/mailgun/scroll/comments{/number}","issue_comment_url":"https://api.github.com/repos/mailgun/scroll/issues/comments{/number}","contents_url":"https://api.github.com/repos/mailgun/scroll/contents/{+path}","compare_url":"https://api.github.com/repos/mailgun/scroll/compare/{base}...{head}","merges_url":"https://api.github.com/repos/mailgun/scroll/merges","archive_url":"https://api.github.com/repos/mailgun/scroll/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/mailgun/scroll/downloads","issues_url":"https://api.github.com/repos/mailgun/scroll/issues{/number}","pulls_url":"https://api.github.com/repos/mailgun/scroll/pulls{/number}","milestones_url":"https://api.github.com/repos/mailgun/scroll/milestones{/number}","notifications_url":"https://api.github.com/repos/mailgun/scroll/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/mailgun/scroll/labels{/name}","releases_url":"https://api.github.com/repos/mailgun/scroll/releases{/id}","created_at":"2014-08-28T17:12:06Z","updated_at":"2015-04-05T19:03:54Z","pushed_at":"2015-04-16T17:57:00Z","git_url":"git://github.com/mailgun/scroll.git","ssh_url":"git@github.com:mailgun/scroll.git","clone_url":"https://github.com/mailgun/scroll.git","svn_url":"https://github.com/mailgun/scroll","homepage":"","size":868,"stargazers_count":33,"watchers_count":33,"language":"Go","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":2,"mirror_url":null,"open_issues_count":5,"forks":2,"open_issues":5,"watchers":33,"default_branch":"master"}},"base":{"label":"mailgun:master","ref":"master","sha":"45e04578294762bdb4a465e57dd7fd7b9c6a0599","user":{"login":"mailgun","id":447686,"avatar_url":"https://avatars.githubusercontent.com/u/447686?v=3","gravatar_id":"","url":"https://api.github.com/users/mailgun","html_url":"https://github.com/mailgun","followers_url":"https://api.github.com/users/mailgun/followers","following_url":"https://api.github.com/users/mailgun/following{/other_user}","gists_url":"https://api.github.com/users/mailgun/gists{/gist_id}","starred_url":"https://api.github.com/users/mailgun/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mailgun/subscriptions","organizations_url":"https://api.github.com/users/mailgun/orgs","repos_url":"https://api.github.com/users/mailgun/repos","events_url":"https://api.github.com/users/mailgun/events{/privacy}","received_events_url":"https://api.github.com/users/mailgun/received_events","type":"Organization","site_admin":false},"repo":{"id":23436353,"name":"scroll","full_name":"mailgun/scroll","owner":{"login":"mailgun","id":447686,"avatar_url":"https://avatars.githubusercontent.com/u/447686?v=3","gravatar_id":"","url":"https://api.github.com/users/mailgun","html_url":"https://github.com/mailgun","followers_url":"https://api.github.com/users/mailgun/followers","following_url":"https://api.github.com/users/mailgun/following{/other_user}","gists_url":"https://api.github.com/users/mailgun/gists{/gist_id}","starred_url":"https://api.github.com/users/mailgun/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mailgun/subscriptions","organizations_url":"https://api.github.com/users/mailgun/orgs","repos_url":"https://api.github.com/users/mailgun/repos","events_url":"https://api.github.com/users/mailgun/events{/privacy}","received_events_url":"https://api.github.com/users/mailgun/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/mailgun/scroll","description":"Scroll is a lightweight library for building Go HTTP services at Mailgun.","fork":false,"url":"https://api.github.com/repos/mailgun/scroll","forks_url":"https://api.github.com/repos/mailgun/scroll/forks","keys_url":"https://api.github.com/repos/mailgun/scroll/keys{/key_id}","collaborators_url":"https://api.github.com/repos/mailgun/scroll/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/mailgun/scroll/teams","hooks_url":"https://api.github.com/repos/mailgun/scroll/hooks","issue_events_url":"https://api.github.com/repos/mailgun/scroll/issues/events{/number}","events_url":"https://api.github.com/repos/mailgun/scroll/events","assignees_url":"https://api.github.com/repos/mailgun/scroll/assignees{/user}","branches_url":"https://api.github.com/repos/mailgun/scroll/branches{/branch}","tags_url":"https://api.github.com/repos/mailgun/scroll/tags","blobs_url":"https://api.github.com/repos/mailgun/scroll/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/mailgun/scroll/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/mailgun/scroll/git/refs{/sha}","trees_url":"https://api.github.com/repos/mailgun/scroll/git/trees{/sha}","statuses_url":"https://api.github.com/repos/mailgun/scroll/statuses/{sha}","languages_url":"https://api.github.com/repos/mailgun/scroll/languages","stargazers_url":"https://api.github.com/repos/mailgun/scroll/stargazers","contributors_url":"https://api.github.com/repos/mailgun/scroll/contributors","subscribers_url":"https://api.github.com/repos/mailgun/scroll/subscribers","subscription_url":"https://api.github.com/repos/mailgun/scroll/subscription","commits_url":"https://api.github.com/repos/mailgun/scroll/commits{/sha}","git_commits_url":"https://api.github.com/repos/mailgun/scroll/git/commits{/sha}","comments_url":"https://api.github.com/repos/mailgun/scroll/comments{/number}","issue_comment_url":"https://api.github.com/repos/mailgun/scroll/issues/comments{/number}","contents_url":"https://api.github.com/repos/mailgun/scroll/contents/{+path}","compare_url":"https://api.github.com/repos/mailgun/scroll/compare/{base}...{head}","merges_url":"https://api.github.com/repos/mailgun/scroll/merges","archive_url":"https://api.github.com/repos/mailgun/scroll/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/mailgun/scroll/downloads","issues_url":"https://api.github.com/repos/mailgun/scroll/issues{/number}","pulls_url":"https://api.github.com/repos/mailgun/scroll/pulls{/number}","milestones_url":"https://api.github.com/repos/mailgun/scroll/milestones{/number}","notifications_url":"https://api.github.com/repos/mailgun/scroll/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/mailgun/scroll/labels{/name}","releases_url":"https://api.github.com/repos/mailgun/scroll/releases{/id}","created_at":"2014-08-28T17:12:06Z","updated_at":"2015-04-05T19:03:54Z","pushed_at":"2015-04-16T17:57:00Z","git_url":"git://github.com/mailgun/scroll.git","ssh_url":"git@github.com:mailgun/scroll.git","clone_url":"https://github.com/mailgun/scroll.git","svn_url":"https://github.com/mailgun/scroll","homepage":"","size":868,"stargazers_count":33,"watchers_count":33,"language":"Go","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":2,"mirror_url":null,"open_issues_count":5,"forks":2,"open_issues":5,"watchers":33,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/mailgun/scroll/pulls/26"},"html":{"href":"https://github.com/mailgun/scroll/pull/26"},"issue":{"href":"https://api.github.com/repos/mailgun/scroll/issues/26"},"comments":{"href":"https://api.github.com/repos/mailgun/scroll/issues/26/comments"},"review_comments":{"href":"https://api.github.com/repos/mailgun/scroll/pulls/26/comments"},"review_comment":{"href":"https://api.github.com/repos/mailgun/scroll/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/mailgun/scroll/pulls/26/commits"},"statuses":{"href":"https://api.github.com/repos/mailgun/scroll/statuses/e25bbc4924e445ff68082dd6bd66932f1da33b0b"}}}}