From 2ac18681b22bb167677a7f64ada9a2e03dee1238 Mon Sep 17 00:00:00 2001
From: nilaoda <nilaoda@live.com>
Date: Thu, 6 Apr 2023 15:20:01 +0800
Subject: [PATCH] fix #141

---
 src/N_m3u8DL-RE.Common/Entity/WebVttSub.cs | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/src/N_m3u8DL-RE.Common/Entity/WebVttSub.cs b/src/N_m3u8DL-RE.Common/Entity/WebVttSub.cs
index 77de827..9bcbfe9 100644
--- a/src/N_m3u8DL-RE.Common/Entity/WebVttSub.cs
+++ b/src/N_m3u8DL-RE.Common/Entity/WebVttSub.cs
@@ -78,6 +78,8 @@ namespace N_m3u8DL_RE.Common.Entity
                     if (string.IsNullOrEmpty(line.Trim()))
                     {
                         var payload = string.Join(Environment.NewLine, payloads);
+                        if (string.IsNullOrEmpty(payload.Trim())) continue; //没获取到payload 跳过添加
+
                         var arr = SplitRegex().Split(timeLine.Replace("-->", "")).Where(s => !string.IsNullOrEmpty(s)).ToList();
                         var startTime = ConvertToTS(arr[0]);
                         var endTime = ConvertToTS(arr[1]);