From 72326844cd9677085e406c5a4ff8b42897b58ea0 Mon Sep 17 00:00:00 2001
From: Eric Bailey <git@esb.lol>
Date: Fri, 22 Nov 2024 08:45:59 -0600
Subject: Improve error name and message for signed-in only feeds (#6577)

* Improve error name and message for logged-in only feeds

* Revert msg edit

---------

Co-authored-by: Dan Abramov <dan.abramov@gmail.com>
---
 src/view/com/posts/FeedErrorMessage.tsx | 10 +++++-----
 1 file changed, 5 insertions(+), 5 deletions(-)

(limited to 'src/view/com/posts/FeedErrorMessage.tsx')

diff --git a/src/view/com/posts/FeedErrorMessage.tsx b/src/view/com/posts/FeedErrorMessage.tsx
index cc7b34750..a58216233 100644
--- a/src/view/com/posts/FeedErrorMessage.tsx
+++ b/src/view/com/posts/FeedErrorMessage.tsx
@@ -25,7 +25,7 @@ export enum KnownError {
   FeedgenBadResponse = 'FeedgenBadResponse',
   FeedgenOffline = 'FeedgenOffline',
   FeedgenUnknown = 'FeedgenUnknown',
-  FeedNSFPublic = 'FeedNSFPublic',
+  FeedSignedInOnly = 'FeedSignedInOnly',
   FeedTooManyRequests = 'FeedTooManyRequests',
   Unknown = 'Unknown',
 }
@@ -110,7 +110,7 @@ function FeedgenErrorMessage({
         [KnownError.FeedgenOffline]: _l(
           msgLingui`Hmm, the feed server appears to be offline. Please let the feed owner know about this issue.`,
         ),
-        [KnownError.FeedNSFPublic]: _l(
+        [KnownError.FeedSignedInOnly]: _l(
           msgLingui`This content is not viewable without a Bluesky account.`,
         ),
         [KnownError.FeedgenUnknown]: _l(
@@ -152,7 +152,7 @@ function FeedgenErrorMessage({
 
   const cta = React.useMemo(() => {
     switch (knownError) {
-      case KnownError.FeedNSFPublic: {
+      case KnownError.FeedSignedInOnly: {
         return null
       }
       case KnownError.FeedgenDoesNotExist:
@@ -249,8 +249,8 @@ function detectKnownError(
   if (typeof error !== 'string') {
     error = error.toString()
   }
-  if (error.includes(KnownError.FeedNSFPublic)) {
-    return KnownError.FeedNSFPublic
+  if (error.includes(KnownError.FeedSignedInOnly)) {
+    return KnownError.FeedSignedInOnly
   }
   if (!feedDesc.startsWith('feedgen')) {
     return KnownError.Unknown
-- 
cgit 1.4.1

