Fix beer likes and db client

This commit is contained in:
Aaron William Po
2023-02-13 13:08:05 -05:00
parent 80261a713b
commit 7240cb0792
6 changed files with 36 additions and 17 deletions

View File

@@ -9,10 +9,6 @@ const useUser = () => {
error,
isLoading,
} = useSWR('/api/users/current', async (url) => {
if (!document.cookie) {
throw new Error('Not logged in.');
}
const response = await fetch(url);
if (!response.ok) {