Skip to content

Commit

Permalink
Fix getToken() #19
Browse files Browse the repository at this point in the history
  • Loading branch information
dimitrov-adrian committed Oct 23, 2021
1 parent 3429420 commit 0bb5f7e
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/interface.vue
Original file line number Diff line number Diff line change
Expand Up @@ -342,7 +342,9 @@ export default defineComponent({
}
function getToken() {
return api.defaults.headers?.['Authorization']?.split(' ')[1] || null;
return api.defaults.headers?.['Authorization']?.split(' ')[1]
|| api.defaults.headers?.common?.['Authorization']?.split(' ')[1]
|| null;
}
function addTokenToURL(url, token) {
Expand Down

0 comments on commit 0bb5f7e

Please sign in to comment.