mirror of
https://github.com/mgerb/go-discord-bot
synced 2026-01-11 09:32:50 +00:00
UI Overhaul
This commit is contained in:
@@ -1,14 +1,9 @@
|
||||
import ax from 'axios';
|
||||
import { StorageService } from './storage.service';
|
||||
|
||||
export const axios = ax.create();
|
||||
|
||||
axios.interceptors.request.use(
|
||||
config => {
|
||||
const jwt = StorageService.getJWT();
|
||||
if (jwt) {
|
||||
config.headers['Authorization'] = `Bearer ${jwt}`;
|
||||
}
|
||||
// Do something before request is sent
|
||||
return config;
|
||||
},
|
||||
|
||||
Reference in New Issue
Block a user