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

remove strpos warning when prefix is empty #43

Merged
merged 1 commit into from
Jul 24, 2022
Merged

remove strpos warning when prefix is empty #43

merged 1 commit into from
Jul 24, 2022

Conversation

carlalexander
Copy link
Contributor

This fixes a warning if you try to run the plugin with a WordPress installation without a prefix

PHP Warning:  strpos(): Empty needle in /plugins/index-wp-mysql-for-speed/code/imsfdb.php on line 66

Copy link
Owner

@OllieJones OllieJones left a comment

Choose a reason for hiding this comment

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

Looks good, thank you. An empty prefix is a use-case I didn't consider.

@OllieJones OllieJones merged commit aed32d4 into OllieJones:main Jul 24, 2022
OllieJones added a commit that referenced this pull request Jul 24, 2022
@carlalexander carlalexander deleted the prefix-warning branch July 25, 2022 23:04
@OllieJones
Copy link
Owner

For what it's worth, WordPress's 6.0.1 installer refuses to build a site with an empty table-name prefix.

@carlalexander
Copy link
Contributor Author

Well, the thing was that I didn't do this on a new site. I ran this on a 14yo WordPress site. So they probably allowed it back then 🤣

@OllieJones
Copy link
Owner

Yeah, I figured. WordPress from antiquity. We did fix the bug.

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.

None yet

2 participants