modified: serv_nginx/bbvue/src/stores/auth.js
change paths for url avatar manipulation
This commit is contained in:
@@ -132,7 +132,7 @@ export const useAuthStore = defineStore('auth', () => {
|
||||
loading.value = true
|
||||
error.value = ''
|
||||
|
||||
const response = await apiClient.post('/user/avatar/upload', formData, {
|
||||
const response = await apiClient.post('/user/avatars/upload', formData, {
|
||||
headers: {
|
||||
'Content-Type': 'multipart/form-data'
|
||||
}
|
||||
@@ -168,7 +168,7 @@ export const useAuthStore = defineStore('auth', () => {
|
||||
|
||||
const deleteAvatar = async () => {
|
||||
try {
|
||||
const response = await apiClient.delete('/user/avatar/delete')
|
||||
const response = await apiClient.delete('/user/avatars/delete')
|
||||
|
||||
if (response.data.success) {
|
||||
// Удаляем аватар из стора
|
||||
|
||||
Reference in New Issue
Block a user