Browse Source

!2 fix time bug

pcacc 3 months ago
parent
commit
45c0d5f4fa
1 changed files with 2 additions and 0 deletions
  1. 2 0
      dongri_task.py

+ 2 - 0
dongri_task.py

@@ -60,6 +60,8 @@ def get_todo_time(todo_str):
     return None
 
 def is_within_n_minutes(target_time_str, n_minutes_left, n_minutes_right):
+    if target_time_str == None:
+        return False
     # 获取当前时间
     now = datetime.now()