Skip to content

Commit

Permalink
fix unknown threadgates
Browse files Browse the repository at this point in the history
  • Loading branch information
mozzius committed Feb 7, 2025
1 parent 7d6adb4 commit 4653afc
Showing 1 changed file with 10 additions and 5 deletions.
15 changes: 10 additions & 5 deletions src/components/WhoCanReply.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -204,12 +204,17 @@ function Rules({
<>
<Text
style={[
a.text_sm,
a.text_md,
a.leading_snug,
a.flex_wrap,
t.atoms.text_contrast_medium,
t.atoms.text_contrast_high,
]}>
{settings[0].type === 'everybody' ? (
{settings.length === 0 ? (
<Trans>
This post has an unknown type of threadgate on it. Your app may be
out of date.
</Trans>
) : settings[0].type === 'everybody' ? (
<Trans>Everybody can reply to this post.</Trans>
) : settings[0].type === 'nobody' ? (
<Trans>Replies to this post are disabled.</Trans>
Expand All @@ -229,10 +234,10 @@ function Rules({
{embeddingDisabled && (
<Text
style={[
a.text_sm,
a.text_md,
a.leading_snug,
a.flex_wrap,
t.atoms.text_contrast_medium,
t.atoms.text_contrast_high,
]}>
<Trans>No one but the author can quote this post.</Trans>
</Text>
Expand Down

0 comments on commit 4653afc

Please sign in to comment.