瀏覽代碼

Fix share status display bug

jerryliao 1 年之前
父節點
當前提交
340526dc7c
共有 1 個文件被更改,包括 3 次插入1 次删除
  1. 3 1
      islands/TopBar.tsx

+ 3 - 1
islands/TopBar.tsx

@@ -30,7 +30,9 @@ export default function TopBar(props: TopBarProps) {
   };
 
   const showShare = () => {
-    shareData["shared"] = shareData["submittedShared"] || props.shared;
+    shareData["shared"] = shareData["submittedShared"] !== undefined
+      ? shareData["submittedShared"]
+      : props.shared;
     window.$modal?.show(
       "Share options",
       <div style="display: flex; align-items: center">