2FAuth/resources/js_vue3/services/userService.js

18 lines
431 B
JavaScript
Raw Normal View History

import { httpClientFactory } from '@/services/httpClientFactory'
const apiClient = httpClientFactory('api')
const webClient = httpClientFactory('web')
export default {
/**
* Update a user preference
*
* @param {string} name
* @param {any} value
* @returns promise
*/
updatePreference(name, value) {
return apiClient.put('/user/preferences/' + name, { value: value })
},
}