mirror of
https://github.com/crater-invoice/crater.git
synced 2025-10-28 04:01:10 -04:00
update env.example and fix token-issue
This commit is contained in:
3
resources/assets/js/bootstrap.js
vendored
3
resources/assets/js/bootstrap.js
vendored
@ -92,8 +92,7 @@ global.axios.interceptors.response.use(undefined, function (err) {
|
||||
if (err.response.data.error === 'invalid_credentials') {
|
||||
window.toastr['error']('Invalid Credentials')
|
||||
}
|
||||
|
||||
if (err.response.data && err.response.statusText === 'Unauthorized') {
|
||||
if (err.response.data && (err.response.statusText === 'Unauthorized' || err.response.data === ' Unauthorized.')) {
|
||||
store.dispatch('auth/logout', true)
|
||||
} else {
|
||||
throw err
|
||||
|
||||
Reference in New Issue
Block a user