diff --git a/plugins/discourse-narrative-bot/lib/discourse_narrative_bot/certificate_generator.rb b/plugins/discourse-narrative-bot/lib/discourse_narrative_bot/certificate_generator.rb index 5e25bb851f0..411cf1c8a27 100644 --- a/plugins/discourse-narrative-bot/lib/discourse_narrative_bot/certificate_generator.rb +++ b/plugins/discourse-narrative-bot/lib/discourse_narrative_bot/certificate_generator.rb @@ -80,6 +80,7 @@ module DiscourseNarrativeBot end def base64_image_data(data) + return "" if data.blank? "xlink:href=\"data:image/png;base64,#{Base64.strict_encode64(data)}\"" end