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

Image Editor Imagick: Always return the WP_Error object of parent call #566

Merged
merged 1 commit into from
Mar 2, 2022

Conversation

ocean90
Copy link
Contributor

@ocean90 ocean90 commented Feb 22, 2022

If WP_Image_Editor_Imagick::_save() returns a WP_Error but no temp filename exists the WP_Error should still be returned. This prevents a fatal error Cannot use object of type WP_Error as array for the $copy_result = copy( $save['path'], $filename ); line.

If `WP_Image_Editor_Imagick::_save()` returns a `WP_Error` but no temp filename exists the `WP_Error` should still be returned. This prevents a fatal error `Cannot use object of type WP_Error as array` for the `$copy_result = copy( $save['path'], $filename );` line.
@joehoyle
Copy link
Member

joehoyle commented Mar 2, 2022

Thanks @ocean90 !

@joehoyle joehoyle merged commit 10c5e24 into humanmade:master Mar 2, 2022
@grappler grappler deleted the fix/imagick-fatal-error branch March 3, 2022 08:55
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.

2 participants