diff options
| author | Omar Roth <omarroth@protonmail.com> | 2019-06-07 21:39:32 -0500 |
|---|---|---|
| committer | Omar Roth <omarroth@protonmail.com> | 2019-06-07 21:39:32 -0500 |
| commit | 801dffd571ea9b0789da00fd0cfb2aae70e4e352 (patch) | |
| tree | b121c16dcba0250f9e53204cc630616d8afcf75d /src | |
| parent | 0b1c57b39f66ca34f88bfeb96d2cd1cafb37a1c6 (diff) | |
| download | invidious-801dffd571ea9b0789da00fd0cfb2aae70e4e352.tar.gz invidious-801dffd571ea9b0789da00fd0cfb2aae70e4e352.tar.bz2 invidious-801dffd571ea9b0789da00fd0cfb2aae70e4e352.zip | |
Fix RSS content-type
Diffstat (limited to 'src')
| -rw-r--r-- | src/invidious.cr | 6 | ||||
| -rw-r--r-- | src/invidious/helpers/utils.cr | 2 |
2 files changed, 4 insertions, 4 deletions
diff --git a/src/invidious.cr b/src/invidious.cr index 97de3fd0..63c44177 100644 --- a/src/invidious.cr +++ b/src/invidious.cr @@ -2439,7 +2439,7 @@ end get "/feed/channel/:ucid" do |env| locale = LOCALES[env.get("preferences").as(Preferences).locale]? - env.response.content_type = "text/xml; charset=UTF-8" + env.response.content_type = "application/atom+xml" ucid = env.params.url["ucid"] @@ -2513,7 +2513,7 @@ end get "/feed/private" do |env| locale = LOCALES[env.get("preferences").as(Preferences).locale]? - env.response.content_type = "text/xml; charset=UTF-8" + env.response.content_type = "application/atom+xml" token = env.params.query["token"]? @@ -2557,7 +2557,7 @@ end get "/feed/playlist/:plid" do |env| locale = LOCALES[env.get("preferences").as(Preferences).locale]? - env.response.content_type = "text/xml; charset=UTF-8" + env.response.content_type = "application/atom+xml" plid = env.params.url["plid"] diff --git a/src/invidious/helpers/utils.cr b/src/invidious/helpers/utils.cr index 3ed067ad..bad2e3a3 100644 --- a/src/invidious/helpers/utils.cr +++ b/src/invidious/helpers/utils.cr @@ -332,7 +332,7 @@ def subscribe_pubsub(topic, key, config) case topic when .match(/^UC[A-Za-z0-9_-]{22}$/) topic = "channel_id=#{topic}" - when .match(/^(?:PL|LL|EC|UU|FL|UL|OLAK5uy_)[0-9A-Za-z-_]{10,}$/) + when .match(/^(PL|LL|EC|UU|FL|UL|OLAK5uy_)[0-9A-Za-z-_]{10,}$/) # There's a couple missing from the above regex, namely TL and RD, which # don't have feeds topic = "playlist_id=#{topic}" |
