浏览代码

Use string.IsNullOrEmpty

Niels van Velzen 1 年之前
父节点
当前提交
0af5373f6d
共有 1 个文件被更改,包括 1 次插入1 次删除
  1. 1 1
      MediaBrowser.Providers/Lyric/DefaultLyricProvider.cs

+ 1 - 1
MediaBrowser.Providers/Lyric/DefaultLyricProvider.cs

@@ -32,7 +32,7 @@ public class DefaultLyricProvider : ILyricProvider
         if (path is not null)
         {
             var content = await File.ReadAllTextAsync(path).ConfigureAwait(false);
-            if (content.Length != 0)
+            if (!string.IsNullOrEmpty(content))
             {
                 return new LyricFile(path, content);
             }