From e6adc0c7ce1efe0d4123bcc0b96013b912c01d8b Mon Sep 17 00:00:00 2001 From: Kohei Yoshino Date: Thu, 24 Jan 2019 14:34:24 -0500 Subject: [PATCH] Bug 1522601 - Uplift request question and answer don't show up as comments --- extensions/FlagTypeComment/web/js/ftc.js | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/extensions/FlagTypeComment/web/js/ftc.js b/extensions/FlagTypeComment/web/js/ftc.js index 84ebda0fe..6fc060182 100644 --- a/extensions/FlagTypeComment/web/js/ftc.js +++ b/extensions/FlagTypeComment/web/js/ftc.js @@ -169,9 +169,11 @@ Bugzilla.FlagTypeComment = class FlagTypeComment { * @returns {Boolean} Always `true` to allow submitting the form. */ form_onsubmit() { - if (this.inserted_fieldsets.length) { - // Enable Markdown - this.$comment.form.querySelector('[name="markdown_off"]').remove(); + const $markdown_off = this.$comment.form.querySelector('input[name="markdown_off"]'); + + // Enable Markdown for any regular patches. Phabricator requests don't come with this hidden `` + if (this.inserted_fieldsets.length && $markdown_off) { + $markdown_off.remove(); } for (const $fieldset of this.inserted_fieldsets) { -- 2.47.3