about summary refs log tree commit diff
path: root/src
diff options
context:
space:
mode:
authorLuke Lucas <52675277+O4FDev@users.noreply.github.com>2024-11-23 20:07:44 +0000
committerGitHub <noreply@github.com>2024-11-23 20:07:44 +0000
commit9663b3e855acfc5a4d3e61211eac253605147e93 (patch)
tree1d59c0bd8bd87ff92d8ab983333e9e1b591af8fb /src
parentf802f81fa6608f2d0c6fb9e8ca65cb42813ef739 (diff)
downloadvoidsky-9663b3e855acfc5a4d3e61211eac253605147e93.tar.zst
fix: nothing selected bug (#6260)
* fix: nothing selected bug

* fix: consolidate related logic for audience settings

* simplify

---------

Co-authored-by: Dan Abramov <dan.abramov@gmail.com>
Diffstat (limited to 'src')
-rw-r--r--src/components/dialogs/PostInteractionSettingsDialog.tsx3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/components/dialogs/PostInteractionSettingsDialog.tsx b/src/components/dialogs/PostInteractionSettingsDialog.tsx
index 81590e3c9..8536001da 100644
--- a/src/components/dialogs/PostInteractionSettingsDialog.tsx
+++ b/src/components/dialogs/PostInteractionSettingsDialog.tsx
@@ -256,6 +256,9 @@ export function PostInteractionSettingsForm({
     } else {
       newSelected.splice(i, 1)
     }
+    if (newSelected.length === 0) {
+      newSelected.push({type: 'everybody'})
+    }
 
     onChangeThreadgateAllowUISettings(newSelected)
   }