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 warning messages when updating #25

Closed
kebekus opened this issue Mar 25, 2020 · 12 comments
Closed

PHP warning messages when updating #25

kebekus opened this issue Mar 25, 2020 · 12 comments
Assignees
Labels

Comments

@kebekus
Copy link

kebekus commented Mar 25, 2020

Thank you for this wonderful plugin.

A while ago I started to see error messages whenever I try to check for updates. More precisely, the command 'wp plugin update --all' returns the following:

PHP Warning: array_merge(): Argument #1 is not an array in /var/www/html/wp-content/plugins/simple-mathjax/simple-mathjax.php on line 29
Warning: array_merge(): Argument #1 is not an array in /var/www/html/wp-content/plugins/simple-mathjax/simple-mathjax.php on line 29
PHP Warning: array_key_exists() expects parameter 2 to be array, null given in /var/www/html/wp-content/plugins/simple-mathjax/simple-mathjax.php on line 46
Warning: array_key_exists() expects parameter 2 to be array, null given in /var/www/html/wp-content/plugins/simple-mathjax/simple-mathjax.php on line 46
PHP Warning: array_key_exists() expects parameter 2 to be array, null given in /var/www/html/wp-content/plugins/simple-mathjax/simple-mathjax.php on line 46
Warning: array_key_exists() expects parameter 2 to be array, null given in /var/www/html/wp-content/plugins/simple-mathjax/simple-mathjax.php on line 46
PHP Warning: array_key_exists() expects parameter 2 to be array, null given in /var/www/html/wp-content/plugins/simple-mathjax/simple-mathjax.php on line 46
Warning: array_key_exists() expects parameter 2 to be array, null given in /var/www/html/wp-content/plugins/simple-mathjax/simple-mathjax.php on line 46
PHP Warning: array_key_exists() expects parameter 2 to be array, null given in /var/www/html/wp-content/plugins/simple-mathjax/simple-mathjax.php on line 46
Warning: array_key_exists() expects parameter 2 to be array, null given in /var/www/html/wp-content/plugins/simple-mathjax/simple-mathjax.php on line 46
PHP Warning: array_key_exists() expects parameter 2 to be array, null given in /var/www/html/wp-content/plugins/simple-mathjax/simple-mathjax.php on line 46
Warning: array_key_exists() expects parameter 2 to be array, null given in /var/www/html/wp-content/plugins/simple-mathjax/simple-mathjax.php on line 46
Success: Plugin already updated.

@pkra
Copy link
Member

pkra commented Mar 25, 2020

Thanks for the report.

@christianp do you have time to take a look?

@pkra pkra added the bug label Mar 25, 2020
christianp added a commit that referenced this issue Mar 25, 2020
I think #25 was caused by another plugin defining a '$default_options'
global.

This commit puts all the functions and default options inside a
'SimpleMathJax' class, which is accessed by namespace. That should avoid
conflicts.
@christianp
Copy link
Collaborator

I've rearranged the code so that everything is under a SimpleMathJax namespace. Can you pull the latest version from GitHub and let me know if that's any better?

@kebekus
Copy link
Author

kebekus commented Mar 25, 2020

Hi, thanks for your very quick response. I puller version 2a5aa9e from GitHub a few minutes ago, and

  • The plugin still works
  • The issue is gone.
    Thanks again!

@christianp
Copy link
Collaborator

Fab! You caught me at the right time.

@pkra
Copy link
Member

pkra commented Mar 25, 2020

Thanks @christianp!

@toddpfaff
Copy link

I need this fix as well. Is it expected that I am not getting this in the most up-to-date version of the simple-mathjax plugin found via wp-cli? wp-cli is telling me that I have version 2.0 and no update is available. Do I have to pull it via git for the time being?

@pkra
Copy link
Member

pkra commented Sep 2, 2020

Hm. Looks like the plugin registry is still at 2.0.

ping @christianp @scoskey do you happen to have access to the Wordpress SVN to push a release? I'm unable to get on at the moment.

@christianp
Copy link
Collaborator

I had changed the Stable tag field in readme.txt as the wordpress docs said, but it seems that I actually needed to change the Version line in simple-mathjax.php.

The wordpress.org plugin page now says that the current version is 2.0.1, so hopefully that has sorted it. @toddpfaff can you tell me if you get the right version now?

@toddpfaff
Copy link

toddpfaff commented Sep 3, 2020 via email

@pkra
Copy link
Member

pkra commented Sep 4, 2020

@toddpaff let us know if the problem persists.

@toddpfaff
Copy link

toddpfaff commented Sep 4, 2020 via email

@pkra
Copy link
Member

pkra commented Sep 4, 2020

Thanks for following up with us.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

4 participants