From 30d9cfedb712f1e2b32b272a18d029b13b79a692 Mon Sep 17 00:00:00 2001 From: benne238 Date: Mon, 11 Jan 2021 14:30:01 -0500 Subject: [PATCH] implementation of blank content handling --- api/ECNQueue.py | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/api/ECNQueue.py b/api/ECNQueue.py index 2cfcf98..28bf904 100644 --- a/api/ECNQueue.py +++ b/api/ECNQueue.py @@ -50,7 +50,8 @@ currentFilePath = __file__ currentFileDirectory = os.path.dirname(currentFilePath) currentFileDirectoryParent = os.path.dirname(currentFileDirectory) -queueDirectory = os.path.join(currentFileDirectoryParent, "q-snapshot") +#queueDirectory = os.path.join(currentFileDirectoryParent, "q-snapshot") +queueDirectory = "/home/pier/e/benne238/personalQueues" # Queues to not load in getQueues() queuesToIgnore = ["archives", "drafts", "inbox", "coral"] @@ -263,6 +264,12 @@ def __parseSections(self) -> list: for assignment in assignementLsit: sections.append(assignment) + # Checks for empty content within an item and returns and + if contentEnd == contentStart: + blankInitialMessage = self.__initialMessageParsing([""]) + sections.append(blankInitialMessage) + return sections + # Checks for Directory Identifiers if self.__rawItem[contentStart] == "\n" and self.__rawItem[contentStart + 1].startswith("\t"): @@ -1345,4 +1352,4 @@ def loadQueues() -> list: for queue in getValidQueues(): queues.append(Queue(queue)) - return queues + return queues \ No newline at end of file