{"action":"created","issue":{"url":"https://api.github.com/repos/siriusphp/validation/issues/22","labels_url":"https://api.github.com/repos/siriusphp/validation/issues/22/labels{/name}","comments_url":"https://api.github.com/repos/siriusphp/validation/issues/22/comments","events_url":"https://api.github.com/repos/siriusphp/validation/issues/22/events","html_url":"https://github.com/siriusphp/validation/issues/22","id":64221314,"number":22,"title":"Reduce the amount of code repeat on labels","user":{"login":"adrianmiu","id":1293017,"avatar_url":"https://avatars.githubusercontent.com/u/1293017?v=3","gravatar_id":"","url":"https://api.github.com/users/adrianmiu","html_url":"https://github.com/adrianmiu","followers_url":"https://api.github.com/users/adrianmiu/followers","following_url":"https://api.github.com/users/adrianmiu/following{/other_user}","gists_url":"https://api.github.com/users/adrianmiu/gists{/gist_id}","starred_url":"https://api.github.com/users/adrianmiu/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/adrianmiu/subscriptions","organizations_url":"https://api.github.com/users/adrianmiu/orgs","repos_url":"https://api.github.com/users/adrianmiu/repos","events_url":"https://api.github.com/users/adrianmiu/events{/privacy}","received_events_url":"https://api.github.com/users/adrianmiu/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/siriusphp/validation/labels/enhancement","name":"enhancement","color":"84b6eb"}],"state":"closed","locked":false,"assignee":{"login":"adrianmiu","id":1293017,"avatar_url":"https://avatars.githubusercontent.com/u/1293017?v=3","gravatar_id":"","url":"https://api.github.com/users/adrianmiu","html_url":"https://github.com/adrianmiu","followers_url":"https://api.github.com/users/adrianmiu/followers","following_url":"https://api.github.com/users/adrianmiu/following{/other_user}","gists_url":"https://api.github.com/users/adrianmiu/gists{/gist_id}","starred_url":"https://api.github.com/users/adrianmiu/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/adrianmiu/subscriptions","organizations_url":"https://api.github.com/users/adrianmiu/orgs","repos_url":"https://api.github.com/users/adrianmiu/repos","events_url":"https://api.github.com/users/adrianmiu/events{/privacy}","received_events_url":"https://api.github.com/users/adrianmiu/received_events","type":"User","site_admin":false},"milestone":null,"comments":1,"created_at":"2015-03-25T09:09:16Z","updated_at":"2015-05-18T12:35:24Z","closed_at":"2015-05-18T12:35:24Z","body":"When a value selector has different validation rules and you want to customize the error message with the label you have to provide the label multiple times\r\n```php\r\n$validator->add(array(\r\n  'preference[*][notification][after][timeout]' => array(\r\n     array('required', null, '{label} is required', 'After Timeout'), \r\n     array('Number', null, '{label} must be a valid number', 'After Timeout'))\r\n ));\r\n```\r\nImplement a way to reduce this code."},"comment":{"url":"https://api.github.com/repos/siriusphp/validation/issues/comments/103043760","html_url":"https://github.com/siriusphp/validation/issues/22#issuecomment-103043760","issue_url":"https://api.github.com/repos/siriusphp/validation/issues/22","id":103043760,"user":{"login":"adrianmiu","id":1293017,"avatar_url":"https://avatars.githubusercontent.com/u/1293017?v=3","gravatar_id":"","url":"https://api.github.com/users/adrianmiu","html_url":"https://github.com/adrianmiu","followers_url":"https://api.github.com/users/adrianmiu/followers","following_url":"https://api.github.com/users/adrianmiu/following{/other_user}","gists_url":"https://api.github.com/users/adrianmiu/gists{/gist_id}","starred_url":"https://api.github.com/users/adrianmiu/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/adrianmiu/subscriptions","organizations_url":"https://api.github.com/users/adrianmiu/orgs","repos_url":"https://api.github.com/users/adrianmiu/repos","events_url":"https://api.github.com/users/adrianmiu/events{/privacy}","received_events_url":"https://api.github.com/users/adrianmiu/received_events","type":"User","site_admin":false},"created_at":"2015-05-18T12:35:24Z","updated_at":"2015-05-18T12:35:24Z","body":"Fixed on version 2.0.0"}}