From bc87bf37f1f062a78582d4908b2bc13f4d4b44d5 Mon Sep 17 00:00:00 2001 From: George Goodall Date: Thu, 16 Jan 2025 11:03:10 +0000 Subject: [PATCH] fix for issue structure check --- src/middleware/entryIssueDetails.middleware.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/middleware/entryIssueDetails.middleware.js b/src/middleware/entryIssueDetails.middleware.js index 02882f8b..1f222bec 100644 --- a/src/middleware/entryIssueDetails.middleware.js +++ b/src/middleware/entryIssueDetails.middleware.js @@ -74,7 +74,7 @@ export const prepareEntry = (req, res, next) => { const issue = entryIssues[0] - if (!(issue.entry_number || issue.entity) || !issue.issue_type || typeof issue.line_number !== 'number') { + if ((!issue.entry_number && !issue.entity && !issue.line_number) || !issue.issue_type || typeof issue.line_number !== 'number') { const error = new Error('Invalid entry issue structure') error.status = 500 return next(error)