From 57111212ea98558b7935501cbdd9ecedc855b550 Mon Sep 17 00:00:00 2001
From: chylex <contact@chylex.com>
Date: Mon, 17 Jul 2023 12:49:43 +0200
Subject: [PATCH] Fix warning message about TweetDeck Preview appearing on
 login screen

---
 resources/Content/tweetdeck/tweetdeck_preview_warning.js | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/resources/Content/tweetdeck/tweetdeck_preview_warning.js b/resources/Content/tweetdeck/tweetdeck_preview_warning.js
index 032eecc2..87be3923 100644
--- a/resources/Content/tweetdeck/tweetdeck_preview_warning.js
+++ b/resources/Content/tweetdeck/tweetdeck_preview_warning.js
@@ -1,7 +1,7 @@
 import { $TD } from "../api/bridge.js";
 
 export default function() {
-	if (!("TD" in window)) {
+	if (location.pathname === "/" && !("TD" in window)) {
 		$TD.alert("warning", "Some TweetDuck features failed to load. This might happen if your Twitter account is enrolled into the TweetDeck Preview, which TweetDuck does not support. Try opting out of the TweetDeck Preview to restore TweetDuck's functionality.");
 	}
 }