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

PHP 8 and psr-4 autoloading support #25

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

faizanakram99
Copy link

No description provided.

@subiabre
Copy link

@Sybio have you had time to review this MR? It fixes #24 and updates the library to PSR which is highly important for this package and the developers who trust it.

I've reviewed it and it looks good to me, if that is of any help. I'm mainly tagging you because I see this pull request has no reviewers assigned so maybe you had not seen it yet.

@gesior
Copy link

gesior commented Sep 10, 2021

There is only one thing missing. In PHP 8.0 images are no longed resources. They are GdImage objects.
I had to change:

if (is_resource($frames[$i])) { // Resource var

to:

if ($frames[$i] instanceof GdImage || is_resource($frames[$i])) { // Resource var

to make it load array of generated images.

- fixes bug for PHP 8+ versions
@faizanakram99
Copy link
Author

@gesior

Thanks, changed

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