From 8b24e0f0b739bb5255006913e07e9d1b59e86179 Mon Sep 17 00:00:00 2001 From: Kane York Date: Thu, 29 Oct 2020 17:57:27 -0700 Subject: [PATCH] FIX: Use <> link instead of code for discobot backup image link (#11063) Due to the new enhanced copy-paste handling, the URL would be included in the user's reply as code, too! By surrounding the link in angle brackets, we prevent the bot from accidentally including the link itself and spoiling the surprise. I considered having the bot automatically edit the user's post to remove the backticks. I very quickly ran into a problem with spurious whitespace, and it would also look _super weird_ for the bot to edit your post when that's not what's being taught. The seemingly bare link not automatically embedding is also weird, but slightly less so. Fun fact: this doesn't work on localhost, because the onebox engine refuses to issue requests to localhost :) --- plugins/discourse-narrative-bot/config/locales/server.en.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/plugins/discourse-narrative-bot/config/locales/server.en.yml b/plugins/discourse-narrative-bot/config/locales/server.en.yml index b55e50a6837..750201811eb 100644 --- a/plugins/discourse-narrative-bot/config/locales/server.en.yml +++ b/plugins/discourse-narrative-bot/config/locales/server.en.yml @@ -199,7 +199,7 @@ en: not_found: |- Looks like you didn’t upload an image so I’ve chosen a picture that I’m _sure_ you will enjoy. - `%{image_url}` + <%{image_url}> Try uploading that one next, or pasting the link in on a line by itself!