Skip to content
This repository has been archived by the owner on Jan 30, 2020. It is now read-only.

Cast keys to string on getting data from object #96

Merged
merged 2 commits into from
Jan 7, 2019
Merged

Cast keys to string on getting data from object #96

merged 2 commits into from
Jan 7, 2019

Conversation

michalbundyra
Copy link
Member

@michalbundyra michalbundyra commented Dec 24, 2018

Fixes:

When extracting data from ArrayObject or another object which int keys we are getting the following error:

Argument 1 passed to Zend\Hydrator\Filter\FilterComposite::filter() must be of the type string, integer given, called in vendor/zendframework/zend-hydrator/src/ArraySerializableHydrator.php on line 39

as we have strict type declaration.

  • Are you fixing a bug?
    • Detail how the bug is invoked currently.
    • Detail the original, incorrect behavior.
    • Detail the new, expected behavior.
    • Base your feature on the master branch, and submit against that branch.
    • Add a regression test that demonstrates the bug, and proves the fix.
    • Add a CHANGELOG.md entry for the fix.

@froschdesign
Copy link
Member

We had already an issue report with this problem but without an unit test. Now the problem is easy to understand. 👍

@tigran-m-dev
Copy link

any news, when this could be merged?

@froschdesign froschdesign added this to the 3.0.1 milestone Jan 5, 2019
@weierophinney weierophinney merged commit 71ab04d into zendframework:master Jan 7, 2019
weierophinney added a commit that referenced this pull request Jan 7, 2019
…keys

Cast keys to string on getting data from object

Conflicts:
	CHANGELOG.md
weierophinney added a commit that referenced this pull request Jan 7, 2019
Forward port #96

Conflicts:
	CHANGELOG.md
@weierophinney
Copy link
Member

Thanks, @webimpress!

@michalbundyra michalbundyra deleted the hotfix/array-serializable-int-keys branch January 7, 2019 22:14
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants