From 9d25b997e4819f4eb047819bcc79b91181f56b98 Mon Sep 17 00:00:00 2001 From: Jack Kavanagh Date: Mon, 24 Jun 2024 15:12:53 +0200 Subject: [PATCH] default to one million second expiry (#173) --- lib/routes/bins/create.js | 2 +- lib/routes/bins/update.js | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/routes/bins/create.js b/lib/routes/bins/create.js index dbfa82c3..842af802 100644 --- a/lib/routes/bins/create.js +++ b/lib/routes/bins/create.js @@ -50,7 +50,7 @@ module.exports = (client) => (req, res, next) => { `bin:${id}`, JSON.stringify(mock), "EX", - process.env.MOCKBIN_REDIS_EXPIRE_SECONDS, + process.env.MOCKBIN_REDIS_EXPIRE_SECONDS || "1000000000", ); res.view = "redirect"; diff --git a/lib/routes/bins/update.js b/lib/routes/bins/update.js index ec348b6d..6aea1f59 100644 --- a/lib/routes/bins/update.js +++ b/lib/routes/bins/update.js @@ -45,7 +45,7 @@ module.exports = (client) => (req, res, next) => { `bin:${compoundId}`, JSON.stringify(mock), "EX", - process.env.MOCKBIN_REDIS_EXPIRE_SECONDS, + process.env.MOCKBIN_REDIS_EXPIRE_SECONDS || "1000000000", ); res.view = "redirect";