crawler keeps hitting the wrong url

i shouldn't cater to it...
This commit is contained in:
Dan Janosik 2024-11-07 16:39:13 -05:00
parent c58166b5bf
commit 66839bdc2d
No known key found for this signature in database
GPG key ID: 70C0B166321C0AF8

View file

@ -1360,6 +1360,12 @@ router.get("/block-analysis", function(req, res, next) {
next();
});
router.get("/tx/tx/:transactionId", asyncHandler(async (req, res, next) => {
res.redirect(301, `${config.baseUrl}tx/${req.params.transactionId}`);
return;
}));
router.get("/tx/:transactionId@:blockHeight", asyncHandler(async (req, res, next) => {
req.query.blockHeight = req.params.blockHeight;
req.url = "/tx/" + req.params.transactionId;