Fix for #4727 #4734

Closed
wants to merge 7 commits into
from

Projects

None yet

3 participants

@pauloelr

Check if parameter is scalar before cast to string
If not throw InvalidArgumentException
Fix for #4727

pauloelr added some commits Jun 26, 2013
@pauloelr pauloelr Fix for #4727
Check if parameter is scalar before cast to string
If not throw InvalidArgumentException
Fix for #4727
667a989
@pauloelr pauloelr Travis Fix
I always forget something about travis
6d56d9a
@pauloelr pauloelr Correction in the variable names d174444
@mwillbanks
Collaborator

@pauloelr please add in unit tests that show the desired exception being raised.

@mwillbanks
Collaborator

Also you should replace "string" with "scalar" in: '%s expects parameter to be string, "%s" given',

pauloelr added some commits Jun 27, 2013
@pauloelr pauloelr Tests Added and Message Changed b0bc5f1
@pauloelr pauloelr Fix for Int Filter
Found one more.
dd4f1dd
@pauloelr pauloelr A Feel More
Check array in:
Zend\Filter\BaseName
Zend\Filter\Digits
Zend\Filter\HtmlEntities
Zend\Filter\RealPath
a07b95a
@pauloelr pauloelr Travis Fix 95628fc
@mwillbanks
Collaborator

@weierophinney since this technically could be a BC break should we target this at develop? More than likely it is not and just fixing a missing check for scalar values but figured I'd get your feedback :)

@weierophinney weierophinney added a commit that referenced this pull request Jun 28, 2013
@weierophinney weierophinney Merge branch 'hotfix/4734' into develop
Forward port #4734
0a2ad79
@weierophinney weierophinney added a commit that closed this pull request Jun 28, 2013
@weierophinney weierophinney Merge branch 'hotfix/4734'
Close #4734
Fixes #4727
4abd198
@weierophinney
Member

@mwillbanks In each case, the filters were designed only to work with strings or integers/floats; these checks fix behavior issues when non-scalars. As such, I consider it a bugfix, and have merged.

This was referenced Jun 29, 2013
@weierophinney weierophinney added a commit to zendframework/zend-filter that referenced this pull request May 15, 2015
@weierophinney weierophinney Merge pull request zendframework/zendframework#4734 from pauloelr/fix…
…_filter_array_to_string

Fix for zendframework/zendframework#4727
d13f3ca
@weierophinney weierophinney added a commit to zendframework/zend-filter that referenced this pull request May 15, 2015
@weierophinney weierophinney Merge branch 'hotfix/4734' e4dc33c
@weierophinney weierophinney added a commit to zendframework/zend-filter that referenced this pull request May 15, 2015
@weierophinney weierophinney Merge branch 'hotfix/4734' into develop d8fa90e
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment