From f2a42755317c110436859ae27198d64d6e3eccb5 Mon Sep 17 00:00:00 2001 From: Andrey Antukh Date: Thu, 16 Nov 2023 19:57:56 +0100 Subject: [PATCH] :bug: Fix unexpected nil key on page-index after page creation --- frontend/src/app/main/data/workspace/persistence.cljs | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/frontend/src/app/main/data/workspace/persistence.cljs b/frontend/src/app/main/data/workspace/persistence.cljs index 0891cb083..4b802b74c 100644 --- a/frontend/src/app/main/data/workspace/persistence.cljs +++ b/frontend/src/app/main/data/workspace/persistence.cljs @@ -259,7 +259,8 @@ (if-let [[page-id changes] (first entries)] (recur (-> fdata (cpc/process-changes changes) - (ctst/update-object-indices page-id)) + (cond-> (some? page-id) + (ctst/update-object-indices page-id))) (rest entries)) fdata)))))) (-> state