Implement dumpENV if in prod environment (#207)

implement dumpENV if in prod environment
This commit is contained in:
Sean Hatfield 2023-08-21 15:38:18 -07:00 committed by GitHub
parent 7ae0d28ef0
commit 4a67cf2198
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -286,6 +286,7 @@ function systemEndpoints(app) {
try {
const body = reqBody(request);
const { newValues, error } = updateENV(body);
if (process.env.NODE_ENV === "production") await dumpENV();
response.status(200).json({ newValues, error });
} catch (e) {
console.log(e.message, e);