removed host from api urls
This commit is contained in:
parent
24abae63f2
commit
097e454069
5 changed files with 10 additions and 11 deletions
2
index.js
2
index.js
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
|
@ -1,5 +1,4 @@
|
||||||
import Request from 'utils/request';
|
import Request from 'utils/request';
|
||||||
const { details: { host } } = require('../../config/siteConfig.js');
|
|
||||||
|
|
||||||
export function getLongClaimId (name, modifier) {
|
export function getLongClaimId (name, modifier) {
|
||||||
let body = {};
|
let body = {};
|
||||||
|
@ -19,17 +18,17 @@ export function getLongClaimId (name, modifier) {
|
||||||
body : JSON.stringify(body),
|
body : JSON.stringify(body),
|
||||||
};
|
};
|
||||||
// create url
|
// create url
|
||||||
const url = `${host}/api/claim/long-id`;
|
const url = `/api/claim/long-id`;
|
||||||
// return the request promise
|
// return the request promise
|
||||||
return Request(url, params);
|
return Request(url, params);
|
||||||
};
|
};
|
||||||
|
|
||||||
export function getShortId (name, claimId) {
|
export function getShortId (name, claimId) {
|
||||||
const url = `${host}/api/claim/short-id/${claimId}/${name}`;
|
const url = `/api/claim/short-id/${claimId}/${name}`;
|
||||||
return Request(url);
|
return Request(url);
|
||||||
};
|
};
|
||||||
|
|
||||||
export function getClaimData (name, claimId) {
|
export function getClaimData (name, claimId) {
|
||||||
const url = `${host}/api/claim/data/${name}/${claimId}`;
|
const url = `/api/claim/data/${name}/${claimId}`;
|
||||||
return Request(url);
|
return Request(url);
|
||||||
};
|
};
|
||||||
|
|
Loading…
Reference in a new issue