mirror of
https://github.com/NohamR/N_m3u8DL-RE.git
synced 2025-07-09 13:37:03 +00:00
UTF-8 with BOM
This commit is contained in:
parent
a0f3709559
commit
71e60af5f3
@ -370,7 +370,7 @@ namespace N_m3u8DL_RE.DownloadManager
|
||||
subContentFixed = OtherUtil.WebVtt2Other(finalVtt, DownloaderConfig.MyOptions.SubtitleFormat);
|
||||
output = Path.ChangeExtension(output, ".srt");
|
||||
}
|
||||
await File.WriteAllTextAsync(path, subContentFixed, new UTF8Encoding(false));
|
||||
await File.WriteAllTextAsync(path, subContentFixed, Encoding.UTF8);
|
||||
FileDic[keys.First()] = new DownloadResult()
|
||||
{
|
||||
ActualContentLength = subContentFixed.Length,
|
||||
@ -405,7 +405,7 @@ namespace N_m3u8DL_RE.DownloadManager
|
||||
subContentFixed = OtherUtil.WebVtt2Other(finalVtt, DownloaderConfig.MyOptions.SubtitleFormat);
|
||||
output = Path.ChangeExtension(output, ".srt");
|
||||
}
|
||||
await File.WriteAllTextAsync(path, subContentFixed, new UTF8Encoding(false));
|
||||
await File.WriteAllTextAsync(path, subContentFixed, Encoding.UTF8);
|
||||
FileDic[firstKey] = new DownloadResult()
|
||||
{
|
||||
ActualContentLength = subContentFixed.Length,
|
||||
@ -438,7 +438,7 @@ namespace N_m3u8DL_RE.DownloadManager
|
||||
subContentFixed = OtherUtil.WebVtt2Other(finalVtt, DownloaderConfig.MyOptions.SubtitleFormat);
|
||||
output = Path.ChangeExtension(output, ".srt");
|
||||
}
|
||||
await File.WriteAllTextAsync(path, subContentFixed, new UTF8Encoding(false));
|
||||
await File.WriteAllTextAsync(path, subContentFixed, Encoding.UTF8);
|
||||
FileDic[firstKey] = new DownloadResult()
|
||||
{
|
||||
ActualContentLength = subContentFixed.Length,
|
||||
@ -475,7 +475,7 @@ namespace N_m3u8DL_RE.DownloadManager
|
||||
subContentFixed = OtherUtil.WebVtt2Other(finalVtt, DownloaderConfig.MyOptions.SubtitleFormat);
|
||||
output = Path.ChangeExtension(output, ".srt");
|
||||
}
|
||||
await File.WriteAllTextAsync(path, subContentFixed, new UTF8Encoding(false));
|
||||
await File.WriteAllTextAsync(path, subContentFixed, Encoding.UTF8);
|
||||
FileDic[firstKey] = new DownloadResult()
|
||||
{
|
||||
ActualContentLength = subContentFixed.Length,
|
||||
|
@ -313,7 +313,7 @@ namespace N_m3u8DL_RE.DownloadManager
|
||||
FileDic.Clear();
|
||||
var path = Path.Combine(tmpDir, Path.GetFileNameWithoutExtension(files.Last()) + ".vtt");
|
||||
var subContentFixed = finalVtt.ToString();
|
||||
await File.WriteAllTextAsync(path, subContentFixed, new UTF8Encoding(false));
|
||||
await File.WriteAllTextAsync(path, subContentFixed, Encoding.UTF8);
|
||||
FileDic[keys.First()] = new DownloadResult()
|
||||
{
|
||||
ActualContentLength = subContentFixed.Length,
|
||||
@ -339,7 +339,7 @@ namespace N_m3u8DL_RE.DownloadManager
|
||||
FileDic.Clear();
|
||||
var path = Path.Combine(tmpDir, Path.GetFileNameWithoutExtension(mp4s.Last()) + ".vtt");
|
||||
var subContentFixed = finalVtt.ToString();
|
||||
await File.WriteAllTextAsync(path, subContentFixed, new UTF8Encoding(false));
|
||||
await File.WriteAllTextAsync(path, subContentFixed, Encoding.UTF8);
|
||||
FileDic[firstKey] = new DownloadResult()
|
||||
{
|
||||
ActualContentLength = subContentFixed.Length,
|
||||
@ -361,7 +361,7 @@ namespace N_m3u8DL_RE.DownloadManager
|
||||
FileDic.Clear();
|
||||
var path = Path.Combine(tmpDir, Path.GetFileNameWithoutExtension(mp4s.Last()) + ".vtt");
|
||||
var subContentFixed = finalVtt.ToString();
|
||||
await File.WriteAllTextAsync(path, subContentFixed, new UTF8Encoding(false));
|
||||
await File.WriteAllTextAsync(path, subContentFixed, Encoding.UTF8);
|
||||
FileDic[firstKey] = new DownloadResult()
|
||||
{
|
||||
ActualContentLength = subContentFixed.Length,
|
||||
@ -387,7 +387,7 @@ namespace N_m3u8DL_RE.DownloadManager
|
||||
FileDic.Clear();
|
||||
var path = Path.Combine(tmpDir, Path.GetFileNameWithoutExtension(mp4s.Last()) + ".vtt");
|
||||
var subContentFixed = finalVtt.ToString();
|
||||
await File.WriteAllTextAsync(path, subContentFixed, new UTF8Encoding(false));
|
||||
await File.WriteAllTextAsync(path, subContentFixed, Encoding.UTF8);
|
||||
FileDic[firstKey] = new DownloadResult()
|
||||
{
|
||||
ActualContentLength = subContentFixed.Length,
|
||||
|
Loading…
x
Reference in New Issue
Block a user