Skip to content

Commit

Permalink
Merge pull request #12 from oderayi/bugfix/fix-transfer-expiration
Browse files Browse the repository at this point in the history
Bugfix: Transfer expiration
  • Loading branch information
oderayi authored Jul 12, 2021
2 parents b1a93d1 + 24515e5 commit 69271df
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 9 deletions.
3 changes: 0 additions & 3 deletions package-lock.json

This file was deleted.

2 changes: 1 addition & 1 deletion src/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion src/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@mojaloop/mock-dfsp-backend",
"version": "8.3.1",
"version": "8.3.2",
"description": "A mock DFSP backend for Mojaloop SDK testing and learning",
"main": "server.js",
"scripts": {
Expand Down
8 changes: 4 additions & 4 deletions src/server.js
Original file line number Diff line number Diff line change
Expand Up @@ -79,16 +79,16 @@ app.get('/parties/:idType/:idValue', async (req, res) => {
app.post('/quoterequests', async (req, res) => {
// always return zero fees
console.log(`Quote request received: ${util.inspect(req.body)}`);

res.send({
const response = {
quoteId: req.body.quoteId,
transactionId: req.body.transactionId,
transferAmount: req.body.amount,
transferAmountCurrency: req.body.currency,
payeeReceiveAmount: req.body.amount,
payeeReceiveAmountCurrency: req.body.currency,
expiration: new Date().toISOString(),
});
}
if (req.body.expiration) response.expiration = req.body.expiration;
res.send(response);
});


Expand Down

0 comments on commit 69271df

Please sign in to comment.