mirror of
https://github.com/zkldi/Tachi.git
synced 2026-10-01 03:18:06 +03:00
fix: critical misstep in folder code (thanks tests)
This commit is contained in:
@@ -190,10 +190,18 @@ export async function CreateFolderChartLookup(folder: FolderDocument, flush = fa
|
||||
|
||||
const ops: Array<BulkWriteOperation<FolderChartLookup>> = charts.map((c) => ({
|
||||
updateOne: {
|
||||
filter: c,
|
||||
filter: {
|
||||
chartID: c.chartID,
|
||||
folderID: folder.folderID,
|
||||
},
|
||||
|
||||
// amusing no-op
|
||||
update: { $set: c },
|
||||
update: {
|
||||
$set: {
|
||||
chartID: c.chartID,
|
||||
folderID: folder.folderID,
|
||||
},
|
||||
},
|
||||
upsert: true,
|
||||
},
|
||||
}));
|
||||
|
||||
Reference in New Issue
Block a user