{"action":"opened","issue":{"url":"https://api.github.com/repos/guillaumepotier/validator.js/issues/29","labels_url":"https://api.github.com/repos/guillaumepotier/validator.js/issues/29/labels{/name}","comments_url":"https://api.github.com/repos/guillaumepotier/validator.js/issues/29/comments","events_url":"https://api.github.com/repos/guillaumepotier/validator.js/issues/29/events","html_url":"https://github.com/guillaumepotier/validator.js/issues/29","id":59401466,"number":29,"title":"Required assert should only check if value is defined ","user":{"login":"fixe","id":484559,"avatar_url":"https://avatars.githubusercontent.com/u/484559?v=3","gravatar_id":"","url":"https://api.github.com/users/fixe","html_url":"https://github.com/fixe","followers_url":"https://api.github.com/users/fixe/followers","following_url":"https://api.github.com/users/fixe/following{/other_user}","gists_url":"https://api.github.com/users/fixe/gists{/gist_id}","starred_url":"https://api.github.com/users/fixe/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/fixe/subscriptions","organizations_url":"https://api.github.com/users/fixe/orgs","repos_url":"https://api.github.com/users/fixe/repos","events_url":"https://api.github.com/users/fixe/events{/privacy}","received_events_url":"https://api.github.com/users/fixe/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":0,"created_at":"2015-03-01T15:53:48Z","updated_at":"2015-03-01T15:53:48Z","closed_at":null,"body":"I think that the assert is doing more than it should. This shouldn't be invalid:\r\n\r\n```js\r\nvalidator.validate({\r\n  foobar: [],\r\n  foobiz: ''\r\n}, {\r\n  foobar: [\r\n    new Assert().Required(),\r\n    new Assert().InstanceOf(Array)\r\n  ],\r\n  foobiz: [\r\n    new Assert().Required()\r\n  ]\r\n});\r\n```\r\n\r\n@guillaumepotier WDYT? Currently I'm overriding the assert but if you agree I can create a PR."}}