Skip to content

Commit

Permalink
fix for issue structure check
Browse files Browse the repository at this point in the history
  • Loading branch information
GeorgeGoodall committed Jan 16, 2025
1 parent a8a4918 commit bc87bf3
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/middleware/entryIssueDetails.middleware.js
Original file line number Diff line number Diff line change
Expand Up @@ -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)
Expand Down

0 comments on commit bc87bf3

Please sign in to comment.