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

Admin_init Hook Issue (With Fix) #61

Open
DawnWakening opened this issue May 13, 2023 · 0 comments
Open

Admin_init Hook Issue (With Fix) #61

DawnWakening opened this issue May 13, 2023 · 0 comments

Comments

@DawnWakening
Copy link

/wp-analytify/classes/analytify-settings.php

admin_init() function should check to make sure the page is set before proceeding. Otherwise, this may conflict with other WP plugins that utilize the admin panel (such as LiteSpeed Cache), without defining a page.

Error:

Warning: Undefined array key "page" in /home/website/public_html/wp-content/plugins/wp-analytify/classes/analytify-settings.php on line 479

Fix:

if ( ('admin.php' === $pagenow) && isset($_GET['page']) && ('analytify-settings' === $_GET['page'] ) || 'options.php' === $pagenow ) {

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

No branches or pull requests

1 participant