Delete note on save when empty print message.

This commit is contained in:
Christian Bastian
2024-04-07 16:28:24 -04:00
parent e518119777
commit 38bfcdf66a

View File

@@ -1044,6 +1044,7 @@ async def set_notes(request):
if text.isspace() or text == "":
if os.path.exists(filename):
os.remove(filename)
print("Deleted file: " + filename)
else:
try:
with open(filename, "w", encoding="utf-8") as f: