Playlist API: return empty author url if ucid is empty (#5618)

This commit is contained in:
Cameron Radmore
2026-02-05 09:59:27 -05:00
committed by GitHub
parent 864893f4c7
commit 84a699f7b7

View File

@@ -107,7 +107,11 @@ struct Playlist
json.field "author", self.author json.field "author", self.author
json.field "authorId", self.ucid json.field "authorId", self.ucid
if !self.ucid.empty?
json.field "authorUrl", "/channel/#{self.ucid}" json.field "authorUrl", "/channel/#{self.ucid}"
else
json.field "authorUrl", ""
end
json.field "subtitle", self.subtitle json.field "subtitle", self.subtitle
json.field "authorThumbnails" do json.field "authorThumbnails" do