enh: cookie auth

This commit is contained in:
Timothy J. Baek
2024-06-19 14:38:09 -07:00
parent 1b100660af
commit b36c525ebc
5 changed files with 42 additions and 12 deletions

View File

@@ -90,7 +90,8 @@ export const getSessionUser = async (token: string) => {
headers: {
'Content-Type': 'application/json',
Authorization: `Bearer ${token}`
}
},
credentials: 'include'
})
.then(async (res) => {
if (!res.ok) throw await res.json();