option_key( 'admin_notices' ) ); if (is_array( self::$notices )) { $notices_cache = self::$notices; foreach($notices_cache as $notice) { echo $notice[ 'notice' ]; if ( ! $notice['persist'] ) { unset( self::$notices[ $notice['key'] ] ); } } update_option( $this->option_key( 'admin_notices' ), self::$notices ); self::$notices = get_option( $this->option_key( 'admin_notices' ) ); } } }