From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from [192.168.2.1] (port=28638 helo=localhost.localdomain) by systemreboot.net with esmtpsa (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.96) (envelope-from ) id 1pCOqL-00113G-2y; Mon, 02 Jan 2023 23:13:26 +0530 From: Arun Isaac To: Ricardo Wurmus Cc: Arun Isaac , 49115-done@debbugs.gnu.org, guile-email@systemreboot.net Subject: [PATCH 1/1] debbugs: Do not check for MIME encoded words in subject. Date: Mon, 2 Jan 2023 17:43:12 +0000 Message-Id: <20230102174312.9685-2-arunisaac@systemreboot.net> X-Mailer: git-send-email 2.38.1 In-Reply-To: <87ilhq5lyw.fsf@elephly.net> References: <87ilhq5lyw.fsf@elephly.net> MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit List-Id: guile-email transparently handles MIME encoded words. We do not have to check for them. * mumi/debbugs.scm (bug-status): Do not check for MIME encoded words in subject. --- mumi/debbugs.scm | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/mumi/debbugs.scm b/mumi/debbugs.scm index 16bff8e..7e95ddf 100644 --- a/mumi/debbugs.scm +++ b/mumi/debbugs.scm @@ -1,5 +1,6 @@ ;;; mumi -- Mediocre, uh, mail interface ;;; Copyright © 2020 Ricardo Wurmus +;;; Copyright © 2023 Arun Isaac ;;; ;;; This program is free software: you can redistribute it and/or ;;; modify it under the terms of the GNU Affero General Public License @@ -280,10 +281,10 @@ defaults to 30 days." (assoc-ref properties "Submitter") (assoc-ref properties "Owner") (or (assoc-ref properties "Severity") "normal") - (let ((subject (or (assoc-ref properties "Subject") ""))) - (if (string-contains subject "=?UTF-8?Q?") - (match (parse-email-headers (string-append "Subject: " subject "\n")) - ((('subject . sub) . rest) sub) - (other subject)) - subject)) + (assq-ref + (parse-email-headers + (string-append "Subject: " + (or (assoc-ref properties "Subject") "") + "\n")) + 'subject) (assoc-ref properties "Tags")))) -- 2.38.1