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

Prevent exception from Whoops when caught exception frame is not related to real file #599

Merged
merged 3 commits into from
Oct 23, 2018

Conversation

SilverFire
Copy link
Contributor

No description provided.

@staabm
Copy link
Contributor

staabm commented Oct 22, 2018

I guess this is a fix for #598

would be great to have a unit-test covering the change.

@lcharette can you verify the fix?

@SilverFire
Copy link
Contributor Author

Yes, seems to be a fix for #598 :)

would be great to have a unit-test covering the change.

Done

@SilverFire SilverFire changed the title Prevent exception from Whools when caught exception frame is not related to real file Prevent exception from Whooзs when caught exception frame is not related to real file Oct 22, 2018
@SilverFire SilverFire changed the title Prevent exception from Whooзs when caught exception frame is not related to real file Prevent exception from Whoops when caught exception frame is not related to real file Oct 22, 2018
*/
public function testGetFileContentsWhenFrameIsNotRelatedToSpecificFile($fakeFilename)
{
$data = array_merge($this->getFrameData(), ['file' => $fakeFilename]);
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I guess we need php 5.x compat here

Suggested change
$data = array_merge($this->getFrameData(), ['file' => $fakeFilename]);
$data = array_merge($this->getFrameData(), array('file' => $fakeFilename));

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

FYI, since you require php 5.5.9 or above, you should be fine.

Following [] is supported in PHP >= 5.4:

@lcharette
Copy link

Looks like it would indeed fix #598. I'll be able to test later today.

@lcharette
Copy link

I can confirm this PR fix my issue in #598

2.3.0 has sailed, this will be in another release.
@denis-sokolov denis-sokolov merged commit 8eb6d53 into filp:master Oct 23, 2018
@denis-sokolov
Copy link
Collaborator

Thank you for your contribution!

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.

4 participants