浏览代码

better camera name handling

Blake Blackshear 4 年之前
父节点
当前提交
3a1f1c946b
共有 1 个文件被更改,包括 2 次插入2 次删除
  1. 2 2
      frigate/events.py

+ 2 - 2
frigate/events.py

@@ -38,8 +38,8 @@ class EventProcessor(threading.Thread):
             if f in files_in_use or f in self.cached_clips:
                 continue
 
-            camera = f.split('-')[0]
-            start_time = datetime.datetime.strptime(f.split('-')[1].split('.')[0], '%Y%m%d%H%M%S')
+            camera = '-'.join(f.split('-')[:-1])
+            start_time = datetime.datetime.strptime(f.split('-')[-1].split('.')[0], '%Y%m%d%H%M%S')
         
             ffprobe_cmd = " ".join([
                 'ffprobe',