Merge branch 'master' into junderw/search-blocktime

This commit is contained in:
Felipe Knorr Kuhn authored and GitHub committed 2022-11-07 07:21:14 -08:00
commit 48e2df3f7a
263 files changed
+83721 -17983

No files matched your search

+6
View File
@@ -239,6 +239,12 @@ class MiningRoutes {
public async $getBlockAudit(req: Request, res: Response) {
try {
const audit = await BlocksAuditsRepository.$getBlockAudit(req.params.hash);
if (!audit) {
res.status(404).send(`This block has not been audited.`);
return;
}
res.header('Pragma', 'public');
res.header('Cache-control', 'public');
res.setHeader('Expires', new Date(Date.now() + 1000 * 3600 * 24).toUTCString());