llms_update_500_legacy_options_autoload_off()
Turn off autoload for accounting legacy options
Contents
Return Return
(bool) True if it needs to run again, false otherwise.
Source Source
File: includes/functions/updates/llms-functions-updates-500.php
function llms_update_500_legacy_options_autoload_off() { global $wpdb; $legacy_options_to_stop_autoloading = array( 'lifterlms_registration_generate_username', 'lifterlms_registration_password_strength', 'lifterlms_registration_password_min_strength', ); $sql = " UPDATE {$wpdb->options} SET autoload='no' WHERE option_name IN (" . implode( ', ', array_fill( 0, count( $legacy_options_to_stop_autoloading ), '%s' ) ) . ')'; $wpdb->query( $wpdb->prepare( $sql, // phpcs:ignore WordPress.DB.PreparedSQL.NotPrepared -- No user input, it's safe. $legacy_options_to_stop_autoloading ) ); // db call ok; no-cache ok. return false; }
Expand full source code Collapse full source code View on GitHub
Changelog Changelog
Version | Description |
---|---|
5.0.0 | Introduced. |