Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions src/components/follow-unfollow-button.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@
profileId,
size = 'medium',
followButtonMinWidth = 120,
onActionFinish = () => {},

Check failure on line 44 in src/components/follow-unfollow-button.tsx

View workflow job for this annotation

GitHub Actions / Static Analysis and Test | Node 20

Unexpected empty arrow function
}: PropsWithChildren<FollowUnfollowButtonProps>) => {
const dispatch = useDispatch();
const [loadProfile, { data: profileData, loading: profileLoading }] = useGetUserLazyQuery();
Expand All @@ -53,14 +53,14 @@
const { sendNotification } = useNotifications();
const { generatePayload } = useNotificationPayload(session);
const profile: User | null = profileData?.getUser;
const isLoading = isProcessing || profileLoading || profileFollowLoading || isFollowingLoading;
const isLoading = isProcessing || profileLoading || profileFollowLoading || isFollowingLoading || !profile;
const RainbowEffect = isLoading ? NeonPaper : Box;

useEffect(() => {
if (profileId && profileId !== session?.address) loadProfile({variables: { input: { address: profileId } }});

if (!profileId) return;
loadProfile({variables: { input: { address: profileId } }});
getIsFollowing({variables: { targetAddress: profileId }});
}, []);
}, [profileId]);

useEffect(() => {
setIsProcessing(false);
Expand Down
Loading