diff --git a/src/controllers/offer.controller.js b/src/controllers/offer.controller.js index 855c10fa..146ab5d8 100644 --- a/src/controllers/offer.controller.js +++ b/src/controllers/offer.controller.js @@ -8,7 +8,7 @@ import { assertStagingTableNotEmpty, } from '../utils/data-assertions'; -import datalayer from '../datalayer/persistance'; +import * as datalayer from '../datalayer/persistance'; export const generateOfferFile = async (req, res) => { try { diff --git a/src/datalayer/persistance.js b/src/datalayer/persistance.js index c27fb786..cc18302c 100644 --- a/src/datalayer/persistance.js +++ b/src/datalayer/persistance.js @@ -372,7 +372,7 @@ const addMirror = async (storeId, url, forceAddMirror = false) => { body: JSON.stringify({ id: storeId, urls: [url], - amount: _.get(CONFIG, 'MIRROR_FEE', 1000000000 /* 1 billion mojos */), + amount: _.get(CONFIG, 'DEFAULT_FEE', 1000000000 /* 1 billion mojos */), }), }; @@ -519,6 +519,8 @@ const cancelOffer = async (tradeId) => { url: `${CONFIG.DATALAYER_URL}/cancel_offer `, body: JSON.stringify({ trade_id: tradeId, + secure: true, + fee: _.get(CONFIG, 'DEFAULT_FEE', 1000000000 /* 1 billion mojos */), }), }; diff --git a/src/utils/defaultConfig.json b/src/utils/defaultConfig.json index 9256922b..e1633de2 100644 --- a/src/utils/defaultConfig.json +++ b/src/utils/defaultConfig.json @@ -14,7 +14,7 @@ "API_KEY": null, "CHIA_NETWORK": "mainnet", "IS_GOVERNANCE_BODY": false, - "MIRROR_FEE": 1000000000 + "DEFAULT_FEE": 1000000000 }, "GOVERNANCE": { "GOVERANCE_BODY_ID": "a8eadac331c82f896d6851a032fd8777605a5c60fc523b0edf7eb75adaf3ba81"