{"action":"opened","issue":{"url":"https://api.github.com/repos/seegno/validator.js-asserts/issues/43","labels_url":"https://api.github.com/repos/seegno/validator.js-asserts/issues/43/labels{/name}","comments_url":"https://api.github.com/repos/seegno/validator.js-asserts/issues/43/comments","events_url":"https://api.github.com/repos/seegno/validator.js-asserts/issues/43/events","html_url":"https://github.com/seegno/validator.js-asserts/issues/43","id":118952612,"number":43,"title":"Add AcceptKeys assert","user":{"login":"ricardogama","id":8616978,"avatar_url":"https://avatars.githubusercontent.com/u/8616978?v=3","gravatar_id":"","url":"https://api.github.com/users/ricardogama","html_url":"https://github.com/ricardogama","followers_url":"https://api.github.com/users/ricardogama/followers","following_url":"https://api.github.com/users/ricardogama/following{/other_user}","gists_url":"https://api.github.com/users/ricardogama/gists{/gist_id}","starred_url":"https://api.github.com/users/ricardogama/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ricardogama/subscriptions","organizations_url":"https://api.github.com/users/ricardogama/orgs","repos_url":"https://api.github.com/users/ricardogama/repos","events_url":"https://api.github.com/users/ricardogama/events{/privacy}","received_events_url":"https://api.github.com/users/ricardogama/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":0,"created_at":"2015-11-26T01:22:56Z","updated_at":"2015-11-26T01:22:56Z","closed_at":null,"body":"I've been using this assert a lot and, validating if an object has invalid keys, which seems handy:\r\n\r\n```js\r\nvalidate({ foo }, {\r\n  foo: new Assert().AcceptKeys(['bar', 'biz'])\r\n}\r\n```\r\n\r\nProducing results like these:\r\n\r\n```js\r\n{ bar: '', biz: '' } // Valid\r\n{ bar: '' } // Valid\r\n{} // Valid\r\n{ bar: '', qux: '' } // Invalid\r\n{ qux: '' } // Invalid\r\n```\r\n\r\n@nunofgs @ruimarinho What do you think, should I open a PR with this feature?"}}