From 9bb479dadfe037a139729421f000620eb0e94895 Mon Sep 17 00:00:00 2001 From: Mylloon Date: Mon, 25 Dec 2023 00:45:12 +0100 Subject: [PATCH] doc: comments --- src/utils/misc.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/utils/misc.py b/src/utils/misc.py index 053b23d..6ec90ce 100644 --- a/src/utils/misc.py +++ b/src/utils/misc.py @@ -32,6 +32,8 @@ def get_posts() -> list[str]: class File: + """file representation""" + def __init__(self, content: str, cdate: str): # content self.content = content @@ -77,6 +79,7 @@ def fresh_file_id() -> int: def exist_post(file_id: int) -> float | None: + """check if post exists, return modification epoch""" try: return os_path.getmtime(post_filename(file_id)) except FileNotFoundError: