pantheon-systems / wordpress-composer-managed

WordPress boilerplate with Composer, easier configuration, and an improved folder structure
https://docs.pantheon.io/guides/wordpress-composer
MIT License
4 stars 4 forks source link

[BUGS-8491] only set `DISABLE_WP_CRON` value once #139

Closed jazzsequence closed 3 months ago

jazzsequence commented 3 months ago

This PR solves several issues.

First and foremost, it resolves an issue created by the fact that DISABLE_WP_CRON was defined twice (once in application.php and once in wp-config-pantheon.php).

The line in application.php has been removed.

The second important change here is that we've moved everything from wp-config-pantheon.php into config/application.pantheon.php. This puts all the Pantheon-specific settings in one place, in the config folder (where Bedrock likes it). The wp-config-pantheon.php file is retained for legacy reasons but the require is removed from wp-config.php (which should not be edited by users on Bedrock sites). The DISABLE_WP_CRON constant is defined in application.pantheon.php as a value that can be overridden if set before the file is loaded in application.php (which allows users the ability to change it if they really need to). Inline comments have been added to reiterate that this is not recommended as well as points out that we do not disable WP Cron on multisite (which the previous comment did not reference at all).