Skip to content

Commit

Permalink
Error parsing for empty headers in Additional info from user section
Browse files Browse the repository at this point in the history
  • Loading branch information
Jacob Daniel Bennett committed Dec 3, 2020
1 parent 3891c05 commit ad4935b
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions api/ECNQueue.py
Original file line number Diff line number Diff line change
Expand Up @@ -915,6 +915,12 @@ def __userReplyParsing(self, replyContent: list, lineNumber: int) -> dict:
if line == "\n":
newLineCounter = newLineCounter + 1

if newLineCounter == 2:

if "datetime" not in replyFromInfo.keys():
errorMessage = "Expected \"Date: [datetime]\" in the header info"
return self.__errorParsing(line, lineNumber + lineNum + 1, errorMessage)

elif line == "===============================================\n":
endingDelimiterCount = endingDelimiterCount + 1

Expand Down

0 comments on commit ad4935b

Please sign in to comment.