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