fix error handling for following-feed

This commit is contained in:
Hazel K 2024-10-02 00:09:10 -04:00
parent ce5c156e42
commit 8f14fec45b

View file

@ -89,7 +89,11 @@ async function selectUser(userId: string): Promise<void> {
.then(user => selectedUser.value = user)
.catch(error => {
console.error('Error fetching user info', error);
return selectedUserError.value = String(error);
return selectedUserError.value =
typeof(error) === 'string'
? String(error)
: JSON.stringify(error);
});
}
}