insert(PreviousText::DB_TABLE, [ 'object_type' => $object_type, 'object_id' => $object_id, 'md' => $md, 'ts' => $ts ]); } static function delete(int $object_type, int|array $object_id): void { $sql = "DELETE FROM ".PreviousText::DB_TABLE." WHERE object_type=? AND object_id"; $args = [$object_type]; if (is_array($object_id)) $sql .= " IN (".implode(',', $object_id).")"; else { $sql .= '=?'; $args[] = $object_id; } DB()->query($sql, ...$args); } }