{"action":"created","issue":{"url":"https://api.github.com/repos/zfcampus/zf-content-validation/issues/85","repository_url":"https://api.github.com/repos/zfcampus/zf-content-validation","labels_url":"https://api.github.com/repos/zfcampus/zf-content-validation/issues/85/labels{/name}","comments_url":"https://api.github.com/repos/zfcampus/zf-content-validation/issues/85/comments","events_url":"https://api.github.com/repos/zfcampus/zf-content-validation/issues/85/events","html_url":"https://github.com/zfcampus/zf-content-validation/issues/85","id":171806878,"number":85,"title":"apigility: filters in `input_filter_specs` not working","user":{"login":"samsonasik","id":459648,"avatar_url":"https://avatars.githubusercontent.com/u/459648?v=3","gravatar_id":"","url":"https://api.github.com/users/samsonasik","html_url":"https://github.com/samsonasik","followers_url":"https://api.github.com/users/samsonasik/followers","following_url":"https://api.github.com/users/samsonasik/following{/other_user}","gists_url":"https://api.github.com/users/samsonasik/gists{/gist_id}","starred_url":"https://api.github.com/users/samsonasik/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/samsonasik/subscriptions","organizations_url":"https://api.github.com/users/samsonasik/orgs","repos_url":"https://api.github.com/users/samsonasik/repos","events_url":"https://api.github.com/users/samsonasik/events{/privacy}","received_events_url":"https://api.github.com/users/samsonasik/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":8,"created_at":"2016-08-18T02:54:04Z","updated_at":"2016-08-18T10:03:50Z","closed_at":"2016-08-18T09:46:09Z","body":"Steps to reproduce:\r\n\r\n- define `input_filter_specs` config:\r\n```php\r\n        'ApiName\\\\V1\\\\Rpc\\\\Register\\\\Validator' => array(\r\n            0 => array(\r\n                'required' => true,\r\n                'validators' => array(\r\n                     0 => array(\r\n                        'name' => 'Zend\\\\Validator\\\\StringLength',\r\n                        'options' => array(\r\n                            'min' => '1',\r\n                            'max' => '100',\r\n                        ),\r\n                   ),\r\n                ),\r\n                'filters' => array(\r\n                    0 => array(\r\n                        'name' => 'Zend\\\\Filter\\\\StringTrim',\r\n                        'options' => array(),\r\n                    ),\r\n                ),\r\n                'name' => 'name',\r\n                'description' => 'Version Name',\r\n                'error_message' => 'Invalid version name',\r\n            ),\r\n        ),\r\n```\r\n- try send name:\r\n```javascript\r\n{ \"name\" : \"foo   \" }\r\n```\r\n- try echo `echo $this->bodyParam('name');` in controller \r\n```php\r\necho $this->bodyParam('name'); // echoed 'foo  ' with space in the right\r\n```\r\n\r\nwith `Zend\\\\Filter\\\\StringTrim` definition, when a field named `name` sent with space in left and right, it should be trimmed, but at this case, it never trimmed. The `validators` is working, the filter is not. \r\n\r\nIt happen with other filters too."},"comment":{"url":"https://api.github.com/repos/zfcampus/zf-content-validation/issues/comments/240680039","html_url":"https://github.com/zfcampus/zf-content-validation/issues/85#issuecomment-240680039","issue_url":"https://api.github.com/repos/zfcampus/zf-content-validation/issues/85","id":240680039,"user":{"login":"samsonasik","id":459648,"avatar_url":"https://avatars.githubusercontent.com/u/459648?v=3","gravatar_id":"","url":"https://api.github.com/users/samsonasik","html_url":"https://github.com/samsonasik","followers_url":"https://api.github.com/users/samsonasik/followers","following_url":"https://api.github.com/users/samsonasik/following{/other_user}","gists_url":"https://api.github.com/users/samsonasik/gists{/gist_id}","starred_url":"https://api.github.com/users/samsonasik/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/samsonasik/subscriptions","organizations_url":"https://api.github.com/users/samsonasik/orgs","repos_url":"https://api.github.com/users/samsonasik/repos","events_url":"https://api.github.com/users/samsonasik/events{/privacy}","received_events_url":"https://api.github.com/users/samsonasik/received_events","type":"User","site_admin":false},"created_at":"2016-08-18T10:03:50Z","updated_at":"2016-08-18T10:03:50Z","body":"Thank you, re-closed."}}
{"actor":{"display_login":"samsonasik"}}