This PR resolves the issue reported in BUGS-5161 as well as making a number of other minor updates that improve the overall quality of the Solr Power plugin.
The commit that resolves the actual bug is 9e259f8
The whitelist_options filter name was deprecated in WP 5.5 in favor of the more inclusive allowed_options. The resolution is simply using the new filter name.
Unrelatedly, my first quality-of-life improvement was to replace sanity_check with environment_check for similar reasons e296885
When using the plugin locally, if SOLR_PATH is not defined, on activation, the plugin assumes you want to upload a schema. This is likely not the case, but the error message does not tell you what's wrong. This PR updates the error message to indicate that SOLR_PATH is not defined, so if that's the problem, you might know how to fix it. 8a5cbc9
If the plugin is installed on a WordPress multisite, the docs indicate that you should Network Activate the plugin, but that is not enforced. 3f53c37 changes this to wp_die if you activate on a single site of a multisite and links to the Network Admin Plugins page to network activate there.
Grunt actions were not running because of changes to grunt-sass. This PR updates the package.json to require node-sass and implements this in the Gruntfile.
Changes were necessary in the Gruntfile which was calling a parameter that was not (or no longer) supported, resulting in errors when Grunt was run.
Some changes were made to the PHPCS rules to not flag short array syntax ([]) or warn about not aligning equals signs.
Short array syntax was added in PHP 5.4, so there's no reason to require arrays to be written in long form.
Aligning equals signs for variables require additional time (that could be better used elsewhere on more important tasks) to align and re-align variable assignments when new variables are added or renamed.
@kporras07 If it had had any adverse effects when I tried to run the build step, I would have tried to add it back in but nothing bad seemed to happen and everything still worked as expected so ¯_(ツ)_/¯
This PR resolves the issue reported in BUGS-5161 as well as making a number of other minor updates that improve the overall quality of the Solr Power plugin.
whitelist_options
filter name was deprecated in WP 5.5 in favor of the more inclusiveallowed_options
. The resolution is simply using the new filter name.sanity_check
withenvironment_check
for similar reasons e296885SOLR_PATH
is not defined, on activation, the plugin assumes you want to upload a schema. This is likely not the case, but the error message does not tell you what's wrong. This PR updates the error message to indicate thatSOLR_PATH
is not defined, so if that's the problem, you might know how to fix it. 8a5cbc9wp_die
if you activate on a single site of a multisite and links to the Network Admin Plugins page to network activate there.grunt-sass
. This PR updates thepackage.json
to requirenode-sass
and implements this in the Gruntfile.[]
) or warn about not aligning equals signs.fixes #541 related #538