entity_type ); if ( TMDO_Mode_Manager::MODE_DUAL_WRITE === $current ) { $r = TMDO_Mode_Manager::set( $this->entity_type, TMDO_Mode_Manager::MODE_SHADOW_READ ); if ( is_wp_error( $r ) ) { throw new \RuntimeException( 'Promote to shadow_read failed: ' . $r->get_error_message() ); } $this->log( $job, 'Mode: dual_write → shadow_read (verifying flat reads)' ); } else { $this->log( $job, "↪ Already at {$current}; skip promote_shadow" ); } return array( 'status' => 'ok' ); } }