fix: prefixUrl

master
pooya parsa 2019-03-18 22:31:55 +03:30
parent 18e5fa1f7a
commit 09a5382778
1 changed files with 3 additions and 3 deletions

View File

@ -45,13 +45,13 @@ const extendKYInstance = instance => {
} }
export default (ctx, inject) => { export default (ctx, inject) => {
// Set baseURL // Set prefixUrl
const baseURL = process.browser const prefixUrl = process.browser
? '<%= options.browserBaseURL %>' ? '<%= options.browserBaseURL %>'
: (process.env._HTTP_BASE_URL_ || '<%= options.baseURL %>') : (process.env._HTTP_BASE_URL_ || '<%= options.baseURL %>')
const kyDefaults = { const kyDefaults = {
baseURL, prefixUrl,
headers: {} headers: {}
} }