|
|
@@ -61,13 +61,15 @@ app.post("/buy", async (req, res, next) => {
|
|
|
throw Error(JSON.stringify({ error: { name: "Error, request body has no \"txHash\" property!" } }));
|
|
|
}
|
|
|
|
|
|
- //TODO load from headers, or something like that??
|
|
|
+ //TODO load from http headers, or something like that??
|
|
|
if (!req.body.user) {
|
|
|
res.status(400);
|
|
|
throw Error(JSON.stringify({ error: { name: "Error, request body has no \"user\" property!" } }));
|
|
|
}
|
|
|
|
|
|
- let txDetail = await getTransactionDetail(req.body.txHash, "kunicykd@test");
|
|
|
+ let txDetail = await getTransactionDetail(req.body.txHash, req.body.user);
|
|
|
+
|
|
|
+
|
|
|
|
|
|
res.send(txDetail);
|
|
|
}
|