{"action":"opened","issue":{"url":"https://api.github.com/repos/phalcon/cphalcon/issues/10866","labels_url":"https://api.github.com/repos/phalcon/cphalcon/issues/10866/labels{/name}","comments_url":"https://api.github.com/repos/phalcon/cphalcon/issues/10866/comments","events_url":"https://api.github.com/repos/phalcon/cphalcon/issues/10866/events","html_url":"https://github.com/phalcon/cphalcon/issues/10866","id":104095733,"number":10866,"title":"[NFR] Dispatcher::getParam return defaultValue if sanitized length is 0","user":{"login":"lajosbencz","id":8420835,"avatar_url":"https://avatars.githubusercontent.com/u/8420835?v=3","gravatar_id":"","url":"https://api.github.com/users/lajosbencz","html_url":"https://github.com/lajosbencz","followers_url":"https://api.github.com/users/lajosbencz/followers","following_url":"https://api.github.com/users/lajosbencz/following{/other_user}","gists_url":"https://api.github.com/users/lajosbencz/gists{/gist_id}","starred_url":"https://api.github.com/users/lajosbencz/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/lajosbencz/subscriptions","organizations_url":"https://api.github.com/users/lajosbencz/orgs","repos_url":"https://api.github.com/users/lajosbencz/repos","events_url":"https://api.github.com/users/lajosbencz/events{/privacy}","received_events_url":"https://api.github.com/users/lajosbencz/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":0,"created_at":"2015-08-31T17:28:44Z","updated_at":"2015-08-31T17:28:44Z","closed_at":null,"body":"The current implementation of ```Dispatcher::getParam``` will only return the specified ```defaultValue``` if there is no such key in the parameters array.\r\n\r\nIf ```defaultValue``` argument is ```null```, it should still return the sanitized value, even when empty.\r\nIf ```defaultValue``` is anything but ```null``` and the length of the sanitized parameter is 0, it should return the ```defaultValue```."}}