From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from firstgate.proxmox.com (firstgate.proxmox.com [212.224.123.68]) by lore.proxmox.com (Postfix) with ESMTPS id CE0551FF142 for ; Fri, 19 Jun 2026 11:17:43 +0200 (CEST) Received: from firstgate.proxmox.com (localhost [127.0.0.1]) by firstgate.proxmox.com (Proxmox) with ESMTP id 5A74294E2; Fri, 19 Jun 2026 11:17:43 +0200 (CEST) Date: Fri, 19 Jun 2026 11:16:58 +0200 From: Stoiko Ivanov To: Dominik Csapak Subject: Re: [PATCH pmg-yew-quarantine-gui] mail view: show mark seen/unseen depending on mail state Message-ID: <20260619111658.21f60b72@rosa.proxmox.com> In-Reply-To: <20260609100235.1650066-1-d.csapak@proxmox.com> References: <20260609100235.1650066-1-d.csapak@proxmox.com> X-Mailer: Claws Mail 4.3.1 (GTK 3.24.49; x86_64-pc-linux-gnu) MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-Bm-Milter-Handled: 55990f41-d878-4baa-be0a-ee34c49e34d2 X-Bm-Transport-Timestamp: 1781860623215 X-SPAM-LEVEL: Spam detection results: 0 AWL 0.083 Adjusted score from AWL reputation of From: address BAYES_00 -1.9 Bayes spam probability is 0 to 1% DMARC_MISSING 0.1 Missing DMARC policy KAM_DMARC_STATUS 0.01 Test Rule for DKIM or SPF Failure with Strict Alignment SPF_HELO_NONE 0.001 SPF: HELO does not publish an SPF Record SPF_PASS -0.001 SPF: sender matches SPF record Message-ID-Hash: 2STTCEJD4F7N624GHQZNQZ7FYHA7MRCA X-Message-ID-Hash: 2STTCEJD4F7N624GHQZNQZ7FYHA7MRCA X-MailFrom: s.ivanov@proxmox.com X-Mailman-Rule-Misses: dmarc-mitigation; no-senders; approved; loop; banned-address; emergency; member-moderation; nonmember-moderation; administrivia; implicit-dest; max-recipients; max-size; news-moderation; no-subject; digests; suspicious-header CC: pmg-devel@lists.proxmox.com X-Mailman-Version: 3.3.10 Precedence: list List-Id: Proxmox Mail Gateway development discussion List-Help: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: Thanks for the patch! gave it a spin, works as advertised! looked through the code - and, apart from a small typo - it LGTM. comment inline: On Tue, 9 Jun 2026 12:02:22 +0200 Dominik Csapak wrote: >..snip.. > + > +// deserialization helper for boolean values that can be 1/0/yes/on/off/etc. > +pub(crate) fn deserialize_flexible_bool<'de, D>(deserializer: D) -> Result > +where > + D: serde::Deserializer<'de>, > +{ > + Ok(match Value::deserialize(deserializer)? { > + Value::Bool(b) => b, > + Value::Number(n) => n.as_i64().is_some_and(|v| v != 0), > + Value::String(s) => { > + matches!(s.to_ascii_uppercase().as_str(), "1" | "on" | "yes" | "true") this should be `to_ascii_lowercase()` > + } > + _ => false, > + }) > +} > diff --git a/src/page_mail_view.rs b/src/page_mail_view.rs >..snip..