The "thread" table isn't used anymore

This commit is contained in:
Michael 2021-02-08 07:48:36 +00:00
parent 8f27715d8b
commit ab5a447bc2
6 changed files with 13 additions and 202 deletions

View file

@ -477,18 +477,6 @@ class Post
$affected = max($affected, DBA::affectedRows());
}
$update_fields = DBStructure::getFieldsForTable('thread', $fields);
if (!empty($update_fields)) {
$rows = DBA::selectToArray('post-view', ['id'], $thread_condition);
$ids = array_column($rows, 'id');
if (!DBA::update('thread', $update_fields, ['iid' => $ids])) {
DBA::rollback();
Logger::notice('Updating thread failed', ['fields' => $update_fields, 'condition' => $thread_condition]);
return false;
}
$affected = max($affected, DBA::affectedRows());
}
$update_fields = [];
foreach (Item::USED_FIELDLIST as $field) {
if (array_key_exists($field, $fields)) {