Adds messages

This commit is contained in:
Jonathan Bourdon
2024-06-27 12:38:49 -04:00
parent 8a4bab5a24
commit 8125df5b70
15 changed files with 223 additions and 21 deletions

View File

@@ -15,12 +15,13 @@ export const auth = defineStore({
async login(client, email, password) {
const requestBody = {
emailAddress: email,
email: email,
password: password
};
const response = await client.post(`${baseUrl}/users/login`, requestBody)
this.user = {
accessToken: response.data,
accessToken: response.data.accessToken,
refreshToken: response.data.refreshToken,
}
localStorage.setItem('jwt', this.user.accessToken);