]> git.ipfire.org Git - thirdparty/bugzilla.git/commitdiff
Bug 1542882 - Don't do image preview on security bugs
authorKohei Yoshino <kohei.yoshino@gmail.com>
Mon, 8 Apr 2019 20:54:29 +0000 (16:54 -0400)
committerGitHub <noreply@github.com>
Mon, 8 Apr 2019 20:54:29 +0000 (16:54 -0400)
extensions/BugModal/web/comments.js

index 359612916e6fe93b2192118dc54a701b56cba3b3..ed9c91bf790c05b950a6060d45d44bed6977b9c2 100644 (file)
@@ -523,9 +523,10 @@ Bugzilla.BugModal.Comments = class Comments {
    * @see https://developer.mozilla.org/en-US/docs/Web/API/Network_Information_API
    */
   prepare_inline_attachments() {
-    // Check the connectivity, API support, user setting and sensitive keywords
+    // Check the connectivity, API support, user setting, bug security and sensitive keywords
     if ((navigator.connection && navigator.connection.type === 'cellular') ||
         typeof IntersectionObserver !== 'function' || !BUGZILLA.user.settings.inline_attachments ||
+        BUGZILLA.bug_secure ||
         BUGZILLA.bug_keywords.split(', ').find(keyword => keyword.match(/^(hang|assertion|crash)$/))) {
       return;
     }