synced with master

This commit is contained in:
Gani Georgiev
2024-01-16 13:14:07 +02:00
33 changed files with 51 additions and 41 deletions
@@ -80,9 +80,14 @@
return;
}
// field with the old name exists so there is no need to rename index columns
if (!!collection?.schema?.find((f) => f.name == oldName && !f.toDelete)) {
return;
}
// update indexes on renamed fields
collection.indexes = collection.indexes.map((idx) =>
CommonHelper.replaceIndexColumn(idx, oldName, newName)
CommonHelper.replaceIndexColumn(idx, oldName, newName),
);
}
</script>