The image above, embedded with
![Long](//discourse-meta.s3-us-west-1.amazonaws.com/original/3X/9/a/9a3bc7ce270b38e31e0c1425043b3e51539e3b3a.jpg) will be downloaded locally, and the image src will be replaced with the new url.
The image below, embedded with
![cat](//discourse-meta.s3-us-west-1.amazonaws.com/original/3X/7/6/7685d7c6a3ecc9df487f7e4c32d3cb4ba571b032.jpg) won’t, because of the bug.
What happens is the image is correctly downloaded locally, but then the url replacement won’t work, because the code is looking for a src with
http: prepended to it.
(I’m going to look like a right numpty if this demonstration doesn’t work, but anyway, there’s a fix here: FIX: Handle img src starting with “//” in pull_hotlinked_images job by LeoMcA · Pull Request #4643 · discourse/discourse · GitHub)