Fix playlist content type

This commit is contained in:
Igor Katson 2024-08-10 13:30:02 +01:00
parent 62067b232f
commit 14b023b592
No known key found for this signature in database
GPG key ID: B4EC22B66D61A3F5
3 changed files with 27 additions and 16 deletions

View file

@ -177,15 +177,13 @@ impl HttpApi {
})
.join("\r\n");
(
if cfg!(any(target_os = "macos", target_os = "ios")) {
[(
"Content-Type",
"application/vnd.apple.mpegurl; charset=utf-8",
)]
} else {
// apple mime does not work with VLC on linux
[("Content-Type", "text/plain; charset=utf-8")]
},
[
("Content-Type", "application/mpegurl; charset=utf-8"),
(
"Content-Disposition",
"attachment; filename=\"rqbit-playlist.m3u8\"",
),
],
body,
)
}