From 235000cf415b30b666bde41cf95f9d7d696f1a8c Mon Sep 17 00:00:00 2001 From: Nuckyz <61953774+Nuckyz@users.noreply.github.com> Date: Tue, 16 May 2023 11:53:17 -0300 Subject: [PATCH] Fix handleProtoChange erroring when userSettingsProto is undefined (#1150) --- src/plugins/fakeNitro.tsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/plugins/fakeNitro.tsx b/src/plugins/fakeNitro.tsx index 52a9d25bb..b48a4668b 100644 --- a/src/plugins/fakeNitro.tsx +++ b/src/plugins/fakeNitro.tsx @@ -321,7 +321,7 @@ export default definePlugin({ }, handleProtoChange(proto: any, user: any) { - if ((!proto.appearance && !AppearanceSettingsProto) || !UserSettingsProtoStore) return; + if (proto == null || typeof proto === "string" || !UserSettingsProtoStore || (!proto.appearance && !AppearanceSettingsProto)) return; const premiumType: number = user?.premium_type ?? UserStore?.getCurrentUser()?.premiumType ?? 0;