From 4af3ca86a657916ed2501d4046994117ce938565 Mon Sep 17 00:00:00 2001
From: naskya <m@naskya.net>
Date: Wed, 22 May 2024 04:43:49 +0900
Subject: [PATCH] fix (client): invalid non-null assertion

---
 packages/client/src/components/global/MkStickyContainer.vue | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/packages/client/src/components/global/MkStickyContainer.vue b/packages/client/src/components/global/MkStickyContainer.vue
index 70883205a8..073c7552c6 100644
--- a/packages/client/src/components/global/MkStickyContainer.vue
+++ b/packages/client/src/components/global/MkStickyContainer.vue
@@ -28,7 +28,7 @@ const parentStickyTop = inject<Ref<number>>(CURRENT_STICKY_TOP, ref(0));
 provide(CURRENT_STICKY_TOP, childStickyTop);
 
 const calc = () => {
-	childStickyTop.value = parentStickyTop.value + headerEl.value!.offsetHeight;
+	childStickyTop.value = parentStickyTop.value + (headerEl.value?.offsetHeight ?? 0);
 	headerHeight.value = headerEl.value!.offsetHeight.toString();
 };