WC_Install::add_update_db_notice
Adds the db update notice.
Метод класса: WC_Install{}
Хуков нет.
Возвращает
void. Ничего (null).
Использование
$result = WC_Install::add_update_db_notice();
Список изменений
| С версии 10.3.0 | Введена. |
Код WC_Install::add_update_db_notice() WC Install::add update db notice WC 11.2.2
private static function add_update_db_notice() {
if ( ! \WC_Admin_Notices::has_notice( 'update' ) ) {
\WC_Admin_Notices::add_notice( 'update', true );
}
try {
if ( WC()->is_wc_admin_active() && false !== get_option( 'woocommerce_admin_install_timestamp' ) ) {
\WC_Notes_Run_Db_Update::add_notice();
}
} catch ( Exception $e ) {
wc_get_logger()->error( 'Error adding db update note: ' . $e->getMessage(), array( 'source' => 'wc-updater' ) );
}
}