small fixes
This commit is contained in:
@@ -1,4 +1,4 @@
|
|||||||
import axios from 'axios';
|
import axios from 'axios'
|
||||||
|
|
||||||
axios.defaults.headers.post['Content-Type'] = 'application/x-www-form-urlencoded; charset=UTF-8'
|
axios.defaults.headers.post['Content-Type'] = 'application/x-www-form-urlencoded; charset=UTF-8'
|
||||||
axios.defaults.headers.common['X-Requested-With'] = 'XMLHttpRequest'
|
axios.defaults.headers.common['X-Requested-With'] = 'XMLHttpRequest'
|
||||||
@@ -50,7 +50,7 @@ axios.interceptors.response.use(
|
|||||||
}
|
}
|
||||||
return Promise.reject(error)
|
return Promise.reject(error)
|
||||||
}
|
}
|
||||||
);
|
)
|
||||||
|
|
||||||
const api = axios.create()
|
const api = axios.create()
|
||||||
|
|
||||||
|
|||||||
@@ -85,4 +85,4 @@ const HttpUtils = {
|
|||||||
},
|
},
|
||||||
}
|
}
|
||||||
|
|
||||||
export default HttpUtils;
|
export default HttpUtils
|
||||||
@@ -10,8 +10,8 @@ export interface Link {
|
|||||||
}
|
}
|
||||||
|
|
||||||
function utf8ToBase64(utf8String: string): string {
|
function utf8ToBase64(utf8String: string): string {
|
||||||
const encodedUtf8 = encodeURIComponent(utf8String).replace(/%([0-9A-F]{2})/g, (_, p1) => String.fromCharCode(parseInt(p1, 16)));
|
const encodedUtf8 = encodeURIComponent(utf8String).replace(/%([0-9A-F]{2})/g, (_, p1) => String.fromCharCode(parseInt(p1, 16)))
|
||||||
return btoa(encodedUtf8);
|
return btoa(encodedUtf8)
|
||||||
}
|
}
|
||||||
|
|
||||||
export namespace LinkUtil {
|
export namespace LinkUtil {
|
||||||
|
|||||||
Reference in New Issue
Block a user