fix(2meet-data-optimizer): keep the audit trail of mode changes and snapshot deletions
- TMDO_Logger::notice() is always written to the error log (it had no callers); bridge_mode_changed and snapshot_deleted use it. Since PR-095 info() is silent without WP_DEBUG_LOG, which left no record of who switched a mode or deleted a snapshot (security review L1) - Verify: LoggerTest (notice always logged, info gated), unit 703, integration 585, phpcs, stan - PR: PR-113 (2.3 acceptance security review)
This commit is contained in:
@@ -310,7 +310,7 @@ class TMDO_Snapshot_Manager {
|
||||
}
|
||||
$table = $wpdb->prefix . self::TABLE_SLUG;
|
||||
$deleted = $wpdb->delete( $table, array( 'snapshot_id' => $snapshot_id ), array( '%s' ) ); // phpcs:ignore WordPress.DB
|
||||
TMDO_Logger::info( 'snapshot_deleted', array( 'snapshot_id' => $snapshot_id ) );
|
||||
TMDO_Logger::notice( 'snapshot_deleted', array( 'snapshot_id' => $snapshot_id ) );
|
||||
return false !== $deleted;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user