From 8d47ec714ef9bb098655721cec6d97a101d94c71 Mon Sep 17 00:00:00 2001 From: bbielsa Date: Wed, 3 Nov 2021 19:57:00 -0400 Subject: [PATCH] Add text/xml as a possible mime type for xml file uploads --- src/invidious.cr | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/invidious.cr b/src/invidious.cr index bdecff1d..85053da2 100644 --- a/src/invidious.cr +++ b/src/invidious.cr @@ -818,7 +818,7 @@ post "/data_control" do |env| end end when "import_youtube" - if type == "application/xml" + if type == "application/xml" || type == "text/xml" subscriptions = XML.parse(body) user.subscriptions += subscriptions.xpath_nodes(%q(//outline[@type="rss"])).map do |channel| channel["xmlUrl"].match(/UC[a-zA-Z0-9_-]{22}/).not_nil![0]