mirror of
https://github.com/Xevion/bus-reminder.git
synced 2025-12-07 11:14:34 -06:00
Fix report query parameter not defaulting to 'true'
This commit is contained in:
@@ -90,8 +90,10 @@ export default async function handler(
|
|||||||
}
|
}
|
||||||
|
|
||||||
try {
|
try {
|
||||||
|
logger.debug('Evaluating cron...');
|
||||||
|
|
||||||
let result;
|
let result;
|
||||||
if (process.env.NODE_ENV === 'production' && parseBoolean(req.query.report))
|
if (process.env.NODE_ENV === 'production' && parseBoolean(req.query.report ?? 'true'))
|
||||||
result = await monitorAsync(innerFunction);
|
result = await monitorAsync(innerFunction);
|
||||||
else result = await innerFunction();
|
else result = await innerFunction();
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user