Added a lot of comments to functions in the source code

This commit is contained in:
Veronica K. B. Olsen
2020-05-24 16:42:28 +02:00
parent e1ce93416c
commit c865dbd59b
21 changed files with 273 additions and 82 deletions
+2 -2
View File
@@ -136,7 +136,6 @@ class NWDoc():
"""Save the document via temp file in case of save failure, and
in any case keep a backup of the file.
"""
if self.docHandle is None or not self.docEditable:
return False
@@ -202,7 +201,6 @@ class NWDoc():
"""Parses the document meta tag and returns the path and name as
a list and a string.
"""
if len(self.docMeta) < 14:
# Not enough information
return "", []
@@ -232,6 +230,8 @@ class NWDoc():
@staticmethod
def _assemblePath(tHandle, docExt):
"""Assemble the file path for a given handle.
"""
if tHandle is None:
return None, None
docDir = "data_"+tHandle[0]