Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update array_walk to a foreach loop when validating channels #45

Merged
merged 1 commit into from May 15, 2015

Conversation

WillSewell
Copy link
Contributor

Referencing a private method in array_walk is incompatible with PHP 5.2

@leggetter @mdpye

@stof
Copy link
Contributor

stof commented May 15, 2015

This also fixes the reference mismatch I fixed in #43, so I will close my PR (but it is still interesting to read about reference mismatches)

@WillSewell
Copy link
Contributor Author

Interesting. That's good to know going forward. I'm more inclined to just stick to regular loops in the future. They may be a bit less elegant, but PHP's existing solution to mapping over arrays is far from elegant, and after these issues, does not seem as robust.

@leggetter
Copy link
Contributor

@WillSewell we do have a test that uses multiple channel names.

https://github.com/pusher/pusher-http-php/blob/master/test/unit/triggerUnitTest.php#L50

But our travis tests don't run against 5.2:
https://travis-ci.org/pusher/pusher-http-php

Which is why we didn't catch that. 👍 for using normal "less elegant" for loops.

Referencing a private method in array_walk is incompatible with PHP 5.2
WillSewell added a commit that referenced this pull request May 15, 2015
Update array_walk to a foreach loop when validating channels
@WillSewell WillSewell merged commit e607f6d into master May 15, 2015
@WillSewell WillSewell deleted the fix_php_52_incompatability branch May 15, 2015 11:18
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants