From dc7bebde92a8804300542a9e2886d08bccba29f7 Mon Sep 17 00:00:00 2001 From: revsuine Date: Tue, 5 Nov 2024 17:16:14 +0000 Subject: [PATCH] only test subtype --- gpgmymail | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gpgmymail b/gpgmymail index 0be804b..1125fe0 100755 --- a/gpgmymail +++ b/gpgmymail @@ -44,7 +44,7 @@ def is_message_encrypted(message: email.message.Message) -> bool: Currently just does it by checking the content type header: https://stackoverflow.com/questions/18819126/checking-encryption-status-of-email""" - return message.get_content_type() == "multipart/encrypted" + return message.get_content_subtype() == "encrypted" def encrypt( message: email.message.Message,