{"action":"closed","issue":{"url":"https://api.github.com/repos/otissv/is-schema-valid/issues/3","repository_url":"https://api.github.com/repos/otissv/is-schema-valid","labels_url":"https://api.github.com/repos/otissv/is-schema-valid/issues/3/labels{/name}","comments_url":"https://api.github.com/repos/otissv/is-schema-valid/issues/3/comments","events_url":"https://api.github.com/repos/otissv/is-schema-valid/issues/3/events","html_url":"https://github.com/otissv/is-schema-valid/issues/3","id":151048369,"number":3,"title":"bugs with nested object?","user":{"login":"klausgao","id":11207273,"avatar_url":"https://avatars.githubusercontent.com/u/11207273?v=3","gravatar_id":"","url":"https://api.github.com/users/klausgao","html_url":"https://github.com/klausgao","followers_url":"https://api.github.com/users/klausgao/followers","following_url":"https://api.github.com/users/klausgao/following{/other_user}","gists_url":"https://api.github.com/users/klausgao/gists{/gist_id}","starred_url":"https://api.github.com/users/klausgao/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/klausgao/subscriptions","organizations_url":"https://api.github.com/users/klausgao/orgs","repos_url":"https://api.github.com/users/klausgao/repos","events_url":"https://api.github.com/users/klausgao/events{/privacy}","received_events_url":"https://api.github.com/users/klausgao/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":2,"created_at":"2016-04-26T06:02:06Z","updated_at":"2016-04-26T08:26:09Z","closed_at":"2016-04-26T08:26:09Z","body":"I try this from your example:\r\n\r\n        const commentSchema = {\r\n            comment: 'string',\r\n            commenter: 'string'\r\n        };\r\n\r\n        const schema = {\r\n            title: {type: 'string', required: true},\r\n            author: 'string',\r\n            summary: 'string',\r\n            tags: ['string'],\r\n            comments: [commentSchema],\r\n            views: 'number',\r\n            nestedObj: commentSchema\r\n        };\r\n\r\n        const data = {\r\n            title: 'A journey from krypton',\r\n            author: 'Superman',\r\n            summary: 'The story of how superman traveled to earth.',\r\n            tags: ['superhero', 'DC comics', 'Metropolis'],\r\n            comments: [\r\n                {comment: 'firstComment', commenter: 'someone'},\r\n                {comment: 'anotherComment', commenter: 'someoneElse'}\r\n            ],\r\n            views: 15000,\r\n            nestedObj:  {comment: 'anotherComment', commenter: 'someoneElse'}\r\n        };\r\n\r\n        let _ret = isSchema(schema)(data);\r\n\r\n_ret is always false."}}