cache updated

This commit is contained in:
raja.blaze 2019-09-10 18:38:51 +05:30
parent 723c504c64
commit 1ff0b0062d

View File

@ -32,7 +32,7 @@ import { Request, Response, NextFunction } from "express";
import bodyParser from "body-parser"; import bodyParser from "body-parser";
//import { logger } from "./server/utils"; //import { logger } from "./server/utils";
import swaggerJSDoc from "swagger-jsdoc"; import swaggerJSDoc from "swagger-jsdoc";
import { errorMiddleware } from "./server/middlewares"; import { errorMiddleware, redisMiddleware } from "./server/middlewares";
import { import {
getRepository, getRepository,
In, In,
@ -121,7 +121,7 @@ controllers.forEach(controller => {
// Example Express Rest API endpoints // Example Express Rest API endpoints
import request from 'request-promise'; import request from 'request-promise';
app.get("/api", async (req, res) => { app.get("/api", redisMiddleware('60'), async (req, res) => {
try { try {
let option = req.query.q; let option = req.query.q;
let blockDetails = await latestBlockDetails(); let blockDetails = await latestBlockDetails();