From 645a533f497874ebe07b2d2422a617cf4989d364 Mon Sep 17 00:00:00 2001 From: Chris Sexton Date: Thu, 21 May 2020 14:56:18 -0400 Subject: [PATCH] add text if missing --- plugins/fact/factoid.go | 3 +++ 1 file changed, 3 insertions(+) diff --git a/plugins/fact/factoid.go b/plugins/fact/factoid.go index f473b0e..769ada3 100644 --- a/plugins/fact/factoid.go +++ b/plugins/fact/factoid.go @@ -459,6 +459,9 @@ func (p *FactoidPlugin) sendImage(c bot.Connector, message msg.Message, msg stri Str("msg", msg). Msg("Sending image attachment") if imgSrc != "" { + if txt == "" { + txt = imgSrc + } img := bot.ImageAttachment{ URL: imgSrc, AltTxt: txt,