]> git.ipfire.org Git - thirdparty/bugzilla.git/commitdiff
Bug 1520495 - Crash count table does not detect uplift links in Markdown comments
authorKohei Yoshino <kohei.yoshino@gmail.com>
Wed, 16 Jan 2019 16:09:14 +0000 (11:09 -0500)
committerGitHub <noreply@github.com>
Wed, 16 Jan 2019 16:09:14 +0000 (11:09 -0500)
extensions/BMO/web/js/firefox-crash-table.js

index 3c07fb6815b267b9030bead391ce071294c13f46..4a9d9fcbe2fff76333010b81e3f4878cb6bef61e 100644 (file)
@@ -144,9 +144,9 @@ window.addEventListener('DOMContentLoaded', () => {
       const hgrevs = [];
       let isFirst = false;
       let currentCommentId = "";
-      const aSelector = oldWay ? ".bz_comment_text > a" : ".comment-text > a";
+      const aSelector = oldWay ? ".bz_comment_text > a" : ".comment-text > a, .comment-text > p:first-child > a";
       document.querySelectorAll(aSelector).forEach(a => {
-        const parentId = a.parentNode.attributes.id;
+        const parentId = a.closest(oldWay ? '.bz_comment_text' : '.comment-text').id;
         let hasBugherderKw = false;
         let hasUpliftKw = false;
         if (parentId !== currentCommentId) {