From f7fdf4e44cd9d957c28db3176c37e94021049eda Mon Sep 17 00:00:00 2001 From: Emi Matchu Date: Thu, 1 Feb 2024 07:13:04 -0800 Subject: [PATCH] Don't show a glitch message for Alt Style items being Incompatible MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The intent of this glitch message was that, when UC or Invisible pets hide an item because of a zones-restrict thing, it would still show up in the items panel as fitting a certain zone, whereas it should have been in the "Incompatible" section and having none of its zones applied. But the previously implementation would like, show this message even for items that _were_ correctly marked as Incompatible? And that the server returned no layers for, because it doesn't fit this body type to begin with? (e.g. put a Grarrl hat on a Grarrl, then switch to Acara, and the Grarrl hat is marked Incompatible—but would also show this confusing message; or similarly with switching to Alt Styles) So, when the server just returned no layers for this item to begin with, don't show this message! --- .../wardrobe-2020/WardrobePage/OutfitKnownGlitchesBadge.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/javascript/wardrobe-2020/WardrobePage/OutfitKnownGlitchesBadge.js b/app/javascript/wardrobe-2020/WardrobePage/OutfitKnownGlitchesBadge.js index ab7f4e86..b0f5e039 100644 --- a/app/javascript/wardrobe-2020/WardrobePage/OutfitKnownGlitchesBadge.js +++ b/app/javascript/wardrobe-2020/WardrobePage/OutfitKnownGlitchesBadge.js @@ -29,7 +29,7 @@ function OutfitKnownGlitchesBadge({ appearance }) { item.appearance, ]).filter((l) => l.source === "item"); - if (compatibleItemLayers.length === 0) { + if (compatibleItemLayers.length === 0 && allItemLayers.length > 0) { glitchMessages.push( {item.name} isn't actually compatible with this special pet.