mirror of
https://github.com/samuelthomas2774/nxapi.git
synced 2026-08-26 20:59:07 -05:00
Fix setting friend code when using a presence URL
This commit is contained in:
@@ -82,7 +82,8 @@ export default function Preferences(props: PreferencesProps) {
|
||||
const discord_friend_code_self = discord_presence_source_user?.nsoAccount.user.links.friendCode.id;
|
||||
const [is_discord_friend_code_self, setIsDiscordFriendCodeSelf] = useState(false);
|
||||
useEffect(() => {
|
||||
setIsDiscordFriendCodeSelf(!!discord_presence_source && (!discord_friend_code || discord_friend_code === discord_friend_code_self));
|
||||
setIsDiscordFriendCodeSelf(!!discord_friend_code_self &&
|
||||
(!discord_friend_code || discord_friend_code === discord_friend_code_self));
|
||||
}, [discord_presence_source, discord_friend_code_self]);
|
||||
|
||||
useEventListener(events, 'window:refresh', () => (
|
||||
|
||||
Reference in New Issue
Block a user