Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
can't activate plugin on WpVip, Automattic's own platform because of this!
Automattic's hosting WpVip GO is using advanced caching mechanisms and doesn't allow/expose the database
directly, only throught the
wpsql apiwpdb class.I searched through the plugin and the plugin does not need DB_NAME,
only some test-scripts:
bin-wp/install-wp-tests.sh:9: DB_NAME=$1
bin-wp/install-wp-tests.sh:96: sed $ioption "s/youremptytestdbnamehere/$DB_NAME/" "$WP_TESTS_DIR"/wp-tests-config.php
bin-wp/install-wp-tests.sh:122: mysqladmin create $DB_NAME --user="$DB_USER" --password="$DB_PASS"$EXTRA
I'm not sure what the .sh are for, I can only hope they are for development purposes, because otherwise they might not work on many dockerised/contarinerised systems, etc.
Anyway, I'm pretty sure you don't need the:
if ( ! defined( 'DB_NAME' ) ) { header( 'HTTP/1.0 403 Forbidden' ); die; }