FIX: an `<a>` with a target of _blank wants a new window (#9607)

FIX: an <a> with a target of _blank wants a new window (#9607)

…even if it wraps an image

diff --git a/app/assets/javascripts/discourse/app/lib/intercept-click.js b/app/assets/javascripts/discourse/app/lib/intercept-click.js
index 31a3c46..fc25322 100644
--- a/app/assets/javascripts/discourse/app/lib/intercept-click.js
+++ b/app/assets/javascripts/discourse/app/lib/intercept-click.js
@@ -7,7 +7,7 @@ export function wantsNewWindow(e) {
     e.metaKey ||
     e.ctrlKey ||
     (e.button && e.button !== 0) ||
-    (e.target && e.target.target === "_blank")
+    (e.currentTarget && e.currentTarget.target === "_blank")
   );
 }
 

GitHub sha: d908bf10

This commit appears in #9607 which was merged by eviltrout.