summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorOmar Roth <omarroth@protonmail.com>2019-07-09 11:54:04 -0500
committerOmar Roth <omarroth@protonmail.com>2019-07-09 23:09:16 -0500
commit47f6fe069ad5f807fe21b5a6be9fb76f2fb48d9a (patch)
tree5225dc957ee6cde7d3d74f599681400eead62543 /src
parentaa3c1d930ba4c078f8db42e984b59e961f790c9e (diff)
downloadinvidious-47f6fe069ad5f807fe21b5a6be9fb76f2fb48d9a.tar.gz
invidious-47f6fe069ad5f807fe21b5a6be9fb76f2fb48d9a.tar.bz2
invidious-47f6fe069ad5f807fe21b5a6be9fb76f2fb48d9a.zip
Add fix for unsupported attachment types
Diffstat (limited to 'src')
-rw-r--r--src/invidious/channels.cr7
1 files changed, 6 insertions, 1 deletions
diff --git a/src/invidious/channels.cr b/src/invidious/channels.cr
index b5f2eb04..858fbded 100644
--- a/src/invidious/channels.cr
+++ b/src/invidious/channels.cr
@@ -820,8 +820,13 @@ def fetch_channel_community(ucid, continuation, locale, config, kemal_config, fo
end
end
end
- else
# TODO
+ # when .has_key?("pollRenderer")
+ # attachment = attachment["pollRenderer"]
+ # json.field "type", "poll"
+ else
+ json.field "type", "unknown"
+ json.field "error", "Unrecognized attachment type."
end
end
end