Fix: Display fallback when no category is set

Signed-off-by: Knut Ahlers <knut@ahlers.me>
This commit is contained in:
Knut Ahlers 2021-05-24 21:53:17 +02:00
parent 7bb9e2869d
commit ca55834315
Signed by: luzifer
GPG key ID: 0066F03ED215AD7D

View file

@ -16,7 +16,7 @@ func init() {
tplFuncs.Register("recentGame", genericTemplateFunctionGetter(func(username string, v ...string) (string, error) {
game, _, err := twitch.GetRecentStreamInfo(strings.TrimLeft(username, "#"))
if err != nil && len(v) > 0 {
if len(v) > 0 && (err != nil || game == "") {
return v[0], nil
}