{"comment":{"url":"https://api.github.com/repos/go-ozzo/ozzo-validation/comments/18390319","html_url":"https://github.com/go-ozzo/ozzo-validation/commit/78cb3f98793e4dfb1fc4b4bb78773ecc04e20a2a#commitcomment-18390319","id":18390319,"user":{"login":"v4n","id":6045161,"avatar_url":"https://avatars.githubusercontent.com/u/6045161?v=3","gravatar_id":"","url":"https://api.github.com/users/v4n","html_url":"https://github.com/v4n","followers_url":"https://api.github.com/users/v4n/followers","following_url":"https://api.github.com/users/v4n/following{/other_user}","gists_url":"https://api.github.com/users/v4n/gists{/gist_id}","starred_url":"https://api.github.com/users/v4n/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/v4n/subscriptions","organizations_url":"https://api.github.com/users/v4n/orgs","repos_url":"https://api.github.com/users/v4n/repos","events_url":"https://api.github.com/users/v4n/events{/privacy}","received_events_url":"https://api.github.com/users/v4n/received_events","type":"User","site_admin":false},"position":null,"line":null,"path":null,"commit_id":"78cb3f98793e4dfb1fc4b4bb78773ecc04e20a2a","created_at":"2016-07-26T03:15:07Z","updated_at":"2016-07-26T03:15:07Z","body":"@qiangxue I've also been thinking about wrapping json decode with a function that allows us to whitelist the fields to set in the struct.\r\n\r\nThis would be safer and also exposes the fields that are expected in the request body:\r\n```\r\nvar customer models.Customer\r\ncustomer.InputWhitelist(request.Body, []string{\"Name\"})\r\n// customer now has only the `Name` field set based on the json content in the body\r\n```\r\n\r\n"}}
{"actor":{"display_login":"v4n"}}