{"action":"created","comment":{"url":"https://api.github.com/repos/synapsestudios/synapse-base/pulls/comments/32178685","id":32178685,"diff_hunk":"@@ -0,0 +1,18 @@\n+<?php\n+\n+namespace Synapse\\Validator\\Constraints\\I18n;\n+\n+use Symfony\\Component\\Validator\\Constraints\\Choice as ParentConstraint;\n+\n+class Choice extends ParentConstraint\n+{\n+    public $message         = 'NOT_A_VALID_CHOICE';\n+    public $multipleMessage = 'ONE_OR_MORE_INVALID_VALUES';\n+    public $minMessage      = 'LESS_THAN_MIN_CHOICES_SELECTED';\n+    public $maxMessage      = 'MORE_THAN_MAX_CHOICES_SELECTED';\n+\n+    public function validatedBy()\n+    {\n+        return 'Symfony\\Component\\Validator\\Constraints\\ChoiceValidator';","path":"src/Synapse/Validator/Constraints/I18n/Choice.php","position":16,"original_position":16,"commit_id":"510547c142099d5cb835341908975eedea541ed7","original_commit_id":"510547c142099d5cb835341908975eedea541ed7","user":{"login":"baohx2000","id":486322,"avatar_url":"https://avatars.githubusercontent.com/u/486322?v=3","gravatar_id":"","url":"https://api.github.com/users/baohx2000","html_url":"https://github.com/baohx2000","followers_url":"https://api.github.com/users/baohx2000/followers","following_url":"https://api.github.com/users/baohx2000/following{/other_user}","gists_url":"https://api.github.com/users/baohx2000/gists{/gist_id}","starred_url":"https://api.github.com/users/baohx2000/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/baohx2000/subscriptions","organizations_url":"https://api.github.com/users/baohx2000/orgs","repos_url":"https://api.github.com/users/baohx2000/repos","events_url":"https://api.github.com/users/baohx2000/events{/privacy}","received_events_url":"https://api.github.com/users/baohx2000/received_events","type":"User","site_admin":false},"body":"Does it need to be the parent class' name?  You should also be able to do `parent::class`","created_at":"2015-06-10T23:49:00Z","updated_at":"2015-06-10T23:49:00Z","html_url":"https://github.com/synapsestudios/synapse-base/pull/202#discussion_r32178685","pull_request_url":"https://api.github.com/repos/synapsestudios/synapse-base/pulls/202","_links":{"self":{"href":"https://api.github.com/repos/synapsestudios/synapse-base/pulls/comments/32178685"},"html":{"href":"https://github.com/synapsestudios/synapse-base/pull/202#discussion_r32178685"},"pull_request":{"href":"https://api.github.com/repos/synapsestudios/synapse-base/pulls/202"}}},"pull_request":{"url":"https://api.github.com/repos/synapsestudios/synapse-base/pulls/202","id":36070747,"html_url":"https://github.com/synapsestudios/synapse-base/pull/202","diff_url":"https://github.com/synapsestudios/synapse-base/pull/202.diff","patch_url":"https://github.com/synapsestudios/synapse-base/pull/202.patch","issue_url":"https://api.github.com/repos/synapsestudios/synapse-base/issues/202","number":202,"state":"open","locked":false,"title":"Make validation errors constant-y","user":{"login":"synbot","id":341352,"avatar_url":"https://avatars.githubusercontent.com/u/341352?v=3","gravatar_id":"","url":"https://api.github.com/users/synbot","html_url":"https://github.com/synbot","followers_url":"https://api.github.com/users/synbot/followers","following_url":"https://api.github.com/users/synbot/following{/other_user}","gists_url":"https://api.github.com/users/synbot/gists{/gist_id}","starred_url":"https://api.github.com/users/synbot/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/synbot/subscriptions","organizations_url":"https://api.github.com/users/synbot/orgs","repos_url":"https://api.github.com/users/synbot/repos","events_url":"https://api.github.com/users/synbot/events{/privacy}","received_events_url":"https://api.github.com/users/synbot/received_events","type":"User","site_admin":false},"body":"### Acceptance Criteria\r\n1. Validation errors in api returns constants + variables (which may require some modifications on the front-end i18n stuff to properly render strings like \"The string must be [number] characters long\" for proper formatting)\r\n1. Validator errors should be constants on the corresponding class, not a string variable.\r\n\r\n### Tasks\r\n- Extend all existing validators to properly return the above\r\n\r\n### Additional Notes\r\n- None\r\n","created_at":"2015-05-22T21:33:38Z","updated_at":"2015-06-10T23:49:00Z","closed_at":null,"merged_at":null,"merge_commit_sha":"93ce056d851ed8b3c964c1d4d4d1f6fa29647cd0","assignee":{"login":"zpchavez","id":717690,"avatar_url":"https://avatars.githubusercontent.com/u/717690?v=3","gravatar_id":"","url":"https://api.github.com/users/zpchavez","html_url":"https://github.com/zpchavez","followers_url":"https://api.github.com/users/zpchavez/followers","following_url":"https://api.github.com/users/zpchavez/following{/other_user}","gists_url":"https://api.github.com/users/zpchavez/gists{/gist_id}","starred_url":"https://api.github.com/users/zpchavez/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/zpchavez/subscriptions","organizations_url":"https://api.github.com/users/zpchavez/orgs","repos_url":"https://api.github.com/users/zpchavez/repos","events_url":"https://api.github.com/users/zpchavez/events{/privacy}","received_events_url":"https://api.github.com/users/zpchavez/received_events","type":"User","site_admin":false},"milestone":{"url":"https://api.github.com/repos/synapsestudios/synapse-base/milestones/1","html_url":"https://github.com/synapsestudios/synapse-base/milestones/Sprint%20%E2%88%9E","labels_url":"https://api.github.com/repos/synapsestudios/synapse-base/milestones/1/labels","id":708247,"number":1,"title":"Sprint ∞","description":"","creator":{"login":"bobeagan","id":100226,"avatar_url":"https://avatars.githubusercontent.com/u/100226?v=3","gravatar_id":"","url":"https://api.github.com/users/bobeagan","html_url":"https://github.com/bobeagan","followers_url":"https://api.github.com/users/bobeagan/followers","following_url":"https://api.github.com/users/bobeagan/following{/other_user}","gists_url":"https://api.github.com/users/bobeagan/gists{/gist_id}","starred_url":"https://api.github.com/users/bobeagan/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bobeagan/subscriptions","organizations_url":"https://api.github.com/users/bobeagan/orgs","repos_url":"https://api.github.com/users/bobeagan/repos","events_url":"https://api.github.com/users/bobeagan/events{/privacy}","received_events_url":"https://api.github.com/users/bobeagan/received_events","type":"User","site_admin":false},"open_issues":18,"closed_issues":199,"state":"open","created_at":"2014-07-02T16:10:27Z","updated_at":"2015-06-05T15:44:19Z","due_on":null,"closed_at":null},"commits_url":"https://api.github.com/repos/synapsestudios/synapse-base/pulls/202/commits","review_comments_url":"https://api.github.com/repos/synapsestudios/synapse-base/pulls/202/comments","review_comment_url":"https://api.github.com/repos/synapsestudios/synapse-base/pulls/comments{/number}","comments_url":"https://api.github.com/repos/synapsestudios/synapse-base/issues/202/comments","statuses_url":"https://api.github.com/repos/synapsestudios/synapse-base/statuses/510547c142099d5cb835341908975eedea541ed7","head":{"label":"synapsestudios:feature/202-internationalizable-validation-messages","ref":"feature/202-internationalizable-validation-messages","sha":"510547c142099d5cb835341908975eedea541ed7","user":{"login":"synapsestudios","id":197868,"avatar_url":"https://avatars.githubusercontent.com/u/197868?v=3","gravatar_id":"","url":"https://api.github.com/users/synapsestudios","html_url":"https://github.com/synapsestudios","followers_url":"https://api.github.com/users/synapsestudios/followers","following_url":"https://api.github.com/users/synapsestudios/following{/other_user}","gists_url":"https://api.github.com/users/synapsestudios/gists{/gist_id}","starred_url":"https://api.github.com/users/synapsestudios/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/synapsestudios/subscriptions","organizations_url":"https://api.github.com/users/synapsestudios/orgs","repos_url":"https://api.github.com/users/synapsestudios/repos","events_url":"https://api.github.com/users/synapsestudios/events{/privacy}","received_events_url":"https://api.github.com/users/synapsestudios/received_events","type":"Organization","site_admin":false},"repo":{"id":18157571,"name":"synapse-base","full_name":"synapsestudios/synapse-base","owner":{"login":"synapsestudios","id":197868,"avatar_url":"https://avatars.githubusercontent.com/u/197868?v=3","gravatar_id":"","url":"https://api.github.com/users/synapsestudios","html_url":"https://github.com/synapsestudios","followers_url":"https://api.github.com/users/synapsestudios/followers","following_url":"https://api.github.com/users/synapsestudios/following{/other_user}","gists_url":"https://api.github.com/users/synapsestudios/gists{/gist_id}","starred_url":"https://api.github.com/users/synapsestudios/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/synapsestudios/subscriptions","organizations_url":"https://api.github.com/users/synapsestudios/orgs","repos_url":"https://api.github.com/users/synapsestudios/repos","events_url":"https://api.github.com/users/synapsestudios/events{/privacy}","received_events_url":"https://api.github.com/users/synapsestudios/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/synapsestudios/synapse-base","description":"Base code for the API template","fork":false,"url":"https://api.github.com/repos/synapsestudios/synapse-base","forks_url":"https://api.github.com/repos/synapsestudios/synapse-base/forks","keys_url":"https://api.github.com/repos/synapsestudios/synapse-base/keys{/key_id}","collaborators_url":"https://api.github.com/repos/synapsestudios/synapse-base/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/synapsestudios/synapse-base/teams","hooks_url":"https://api.github.com/repos/synapsestudios/synapse-base/hooks","issue_events_url":"https://api.github.com/repos/synapsestudios/synapse-base/issues/events{/number}","events_url":"https://api.github.com/repos/synapsestudios/synapse-base/events","assignees_url":"https://api.github.com/repos/synapsestudios/synapse-base/assignees{/user}","branches_url":"https://api.github.com/repos/synapsestudios/synapse-base/branches{/branch}","tags_url":"https://api.github.com/repos/synapsestudios/synapse-base/tags","blobs_url":"https://api.github.com/repos/synapsestudios/synapse-base/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/synapsestudios/synapse-base/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/synapsestudios/synapse-base/git/refs{/sha}","trees_url":"https://api.github.com/repos/synapsestudios/synapse-base/git/trees{/sha}","statuses_url":"https://api.github.com/repos/synapsestudios/synapse-base/statuses/{sha}","languages_url":"https://api.github.com/repos/synapsestudios/synapse-base/languages","stargazers_url":"https://api.github.com/repos/synapsestudios/synapse-base/stargazers","contributors_url":"https://api.github.com/repos/synapsestudios/synapse-base/contributors","subscribers_url":"https://api.github.com/repos/synapsestudios/synapse-base/subscribers","subscription_url":"https://api.github.com/repos/synapsestudios/synapse-base/subscription","commits_url":"https://api.github.com/repos/synapsestudios/synapse-base/commits{/sha}","git_commits_url":"https://api.github.com/repos/synapsestudios/synapse-base/git/commits{/sha}","comments_url":"https://api.github.com/repos/synapsestudios/synapse-base/comments{/number}","issue_comment_url":"https://api.github.com/repos/synapsestudios/synapse-base/issues/comments{/number}","contents_url":"https://api.github.com/repos/synapsestudios/synapse-base/contents/{+path}","compare_url":"https://api.github.com/repos/synapsestudios/synapse-base/compare/{base}...{head}","merges_url":"https://api.github.com/repos/synapsestudios/synapse-base/merges","archive_url":"https://api.github.com/repos/synapsestudios/synapse-base/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/synapsestudios/synapse-base/downloads","issues_url":"https://api.github.com/repos/synapsestudios/synapse-base/issues{/number}","pulls_url":"https://api.github.com/repos/synapsestudios/synapse-base/pulls{/number}","milestones_url":"https://api.github.com/repos/synapsestudios/synapse-base/milestones{/number}","notifications_url":"https://api.github.com/repos/synapsestudios/synapse-base/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/synapsestudios/synapse-base/labels{/name}","releases_url":"https://api.github.com/repos/synapsestudios/synapse-base/releases{/id}","created_at":"2014-03-26T23:20:18Z","updated_at":"2015-05-05T23:00:42Z","pushed_at":"2015-06-10T23:35:08Z","git_url":"git://github.com/synapsestudios/synapse-base.git","ssh_url":"git@github.com:synapsestudios/synapse-base.git","clone_url":"https://github.com/synapsestudios/synapse-base.git","svn_url":"https://github.com/synapsestudios/synapse-base","homepage":"","size":2964,"stargazers_count":1,"watchers_count":1,"language":"PHP","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":1,"mirror_url":null,"open_issues_count":19,"forks":1,"open_issues":19,"watchers":1,"default_branch":"master"}},"base":{"label":"synapsestudios:master","ref":"master","sha":"a9a1403f624bf585034d72fbf097783234476891","user":{"login":"synapsestudios","id":197868,"avatar_url":"https://avatars.githubusercontent.com/u/197868?v=3","gravatar_id":"","url":"https://api.github.com/users/synapsestudios","html_url":"https://github.com/synapsestudios","followers_url":"https://api.github.com/users/synapsestudios/followers","following_url":"https://api.github.com/users/synapsestudios/following{/other_user}","gists_url":"https://api.github.com/users/synapsestudios/gists{/gist_id}","starred_url":"https://api.github.com/users/synapsestudios/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/synapsestudios/subscriptions","organizations_url":"https://api.github.com/users/synapsestudios/orgs","repos_url":"https://api.github.com/users/synapsestudios/repos","events_url":"https://api.github.com/users/synapsestudios/events{/privacy}","received_events_url":"https://api.github.com/users/synapsestudios/received_events","type":"Organization","site_admin":false},"repo":{"id":18157571,"name":"synapse-base","full_name":"synapsestudios/synapse-base","owner":{"login":"synapsestudios","id":197868,"avatar_url":"https://avatars.githubusercontent.com/u/197868?v=3","gravatar_id":"","url":"https://api.github.com/users/synapsestudios","html_url":"https://github.com/synapsestudios","followers_url":"https://api.github.com/users/synapsestudios/followers","following_url":"https://api.github.com/users/synapsestudios/following{/other_user}","gists_url":"https://api.github.com/users/synapsestudios/gists{/gist_id}","starred_url":"https://api.github.com/users/synapsestudios/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/synapsestudios/subscriptions","organizations_url":"https://api.github.com/users/synapsestudios/orgs","repos_url":"https://api.github.com/users/synapsestudios/repos","events_url":"https://api.github.com/users/synapsestudios/events{/privacy}","received_events_url":"https://api.github.com/users/synapsestudios/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/synapsestudios/synapse-base","description":"Base code for the API template","fork":false,"url":"https://api.github.com/repos/synapsestudios/synapse-base","forks_url":"https://api.github.com/repos/synapsestudios/synapse-base/forks","keys_url":"https://api.github.com/repos/synapsestudios/synapse-base/keys{/key_id}","collaborators_url":"https://api.github.com/repos/synapsestudios/synapse-base/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/synapsestudios/synapse-base/teams","hooks_url":"https://api.github.com/repos/synapsestudios/synapse-base/hooks","issue_events_url":"https://api.github.com/repos/synapsestudios/synapse-base/issues/events{/number}","events_url":"https://api.github.com/repos/synapsestudios/synapse-base/events","assignees_url":"https://api.github.com/repos/synapsestudios/synapse-base/assignees{/user}","branches_url":"https://api.github.com/repos/synapsestudios/synapse-base/branches{/branch}","tags_url":"https://api.github.com/repos/synapsestudios/synapse-base/tags","blobs_url":"https://api.github.com/repos/synapsestudios/synapse-base/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/synapsestudios/synapse-base/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/synapsestudios/synapse-base/git/refs{/sha}","trees_url":"https://api.github.com/repos/synapsestudios/synapse-base/git/trees{/sha}","statuses_url":"https://api.github.com/repos/synapsestudios/synapse-base/statuses/{sha}","languages_url":"https://api.github.com/repos/synapsestudios/synapse-base/languages","stargazers_url":"https://api.github.com/repos/synapsestudios/synapse-base/stargazers","contributors_url":"https://api.github.com/repos/synapsestudios/synapse-base/contributors","subscribers_url":"https://api.github.com/repos/synapsestudios/synapse-base/subscribers","subscription_url":"https://api.github.com/repos/synapsestudios/synapse-base/subscription","commits_url":"https://api.github.com/repos/synapsestudios/synapse-base/commits{/sha}","git_commits_url":"https://api.github.com/repos/synapsestudios/synapse-base/git/commits{/sha}","comments_url":"https://api.github.com/repos/synapsestudios/synapse-base/comments{/number}","issue_comment_url":"https://api.github.com/repos/synapsestudios/synapse-base/issues/comments{/number}","contents_url":"https://api.github.com/repos/synapsestudios/synapse-base/contents/{+path}","compare_url":"https://api.github.com/repos/synapsestudios/synapse-base/compare/{base}...{head}","merges_url":"https://api.github.com/repos/synapsestudios/synapse-base/merges","archive_url":"https://api.github.com/repos/synapsestudios/synapse-base/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/synapsestudios/synapse-base/downloads","issues_url":"https://api.github.com/repos/synapsestudios/synapse-base/issues{/number}","pulls_url":"https://api.github.com/repos/synapsestudios/synapse-base/pulls{/number}","milestones_url":"https://api.github.com/repos/synapsestudios/synapse-base/milestones{/number}","notifications_url":"https://api.github.com/repos/synapsestudios/synapse-base/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/synapsestudios/synapse-base/labels{/name}","releases_url":"https://api.github.com/repos/synapsestudios/synapse-base/releases{/id}","created_at":"2014-03-26T23:20:18Z","updated_at":"2015-05-05T23:00:42Z","pushed_at":"2015-06-10T23:35:08Z","git_url":"git://github.com/synapsestudios/synapse-base.git","ssh_url":"git@github.com:synapsestudios/synapse-base.git","clone_url":"https://github.com/synapsestudios/synapse-base.git","svn_url":"https://github.com/synapsestudios/synapse-base","homepage":"","size":2964,"stargazers_count":1,"watchers_count":1,"language":"PHP","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":1,"mirror_url":null,"open_issues_count":19,"forks":1,"open_issues":19,"watchers":1,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/synapsestudios/synapse-base/pulls/202"},"html":{"href":"https://github.com/synapsestudios/synapse-base/pull/202"},"issue":{"href":"https://api.github.com/repos/synapsestudios/synapse-base/issues/202"},"comments":{"href":"https://api.github.com/repos/synapsestudios/synapse-base/issues/202/comments"},"review_comments":{"href":"https://api.github.com/repos/synapsestudios/synapse-base/pulls/202/comments"},"review_comment":{"href":"https://api.github.com/repos/synapsestudios/synapse-base/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/synapsestudios/synapse-base/pulls/202/commits"},"statuses":{"href":"https://api.github.com/repos/synapsestudios/synapse-base/statuses/510547c142099d5cb835341908975eedea541ed7"}}}}