Node.js based forum software built for the modern web
wrap images in links even if the images aren't unloaded. handle resized images with no file extension (as seen on wtdwtf) (#4561)
Ben Lubar37bd63ab755d
diff --git a/public/src/client/topic/posts.js b/public/src/client/topic/posts.jsindex 630b91bc72..605994c9e6 100644--- a/public/src/client/topic/posts.js+++ b/public/src/client/topic/posts.js@@ -244,6 +244,7 @@ define('forum/topic/posts', [}).attr('data-state', 'unloaded').attr('src', 'about:blank');} else {images.attr('data-state', 'loaded');+ Posts.wrapImagesInLinks(posts);}};@@ -320,7 +321,7 @@ define('forum/topic/posts', [posts.find('[component="post/content"] img:not(.emoji)').each(function() {var $this = $(this),src = $this.attr('src'),- suffixRegex = /-resized(\.[\w]+)$/;+ suffixRegex = /-resized(\.[\w]+)?$/;if (utils.isRelativeUrl(src) && suffixRegex.test(src)) {src = src.replace(suffixRegex, '$1');