From 5c651151481f6475e0ecb775d3d674c02c8a765f Mon Sep 17 00:00:00 2001 From: Moritz Vetter <16950410+Isokaeder@users.noreply.github.com> Date: Mon, 20 Jan 2025 23:11:39 +0100 Subject: [PATCH] fix(KtStandardTable): validate against manual version if it's provided --- packages/kotti-ui/source/kotti-table/standard-table/storage.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/kotti-ui/source/kotti-table/standard-table/storage.ts b/packages/kotti-ui/source/kotti-table/standard-table/storage.ts index 366e83bdf..88d28e443 100644 --- a/packages/kotti-ui/source/kotti-table/standard-table/storage.ts +++ b/packages/kotti-ui/source/kotti-table/standard-table/storage.ts @@ -127,7 +127,7 @@ export class LocalStorageAdapter implements KottiStandardTableStorage { #validateVersionHash(columnIds: string[], version: string): boolean { if (!version.startsWith(`${this.#storageKey}@`)) return false - const correctHash = simpleHash(columnIds) + const correctHash = this.#manualVersion ?? simpleHash(columnIds) const givenHash = version.replace(`${this.#storageKey}@`, '') return correctHash === givenHash