From cfd294178e5a20a956a49dd67d9d7c701b664d09 Mon Sep 17 00:00:00 2001 From: Martin Mares <mj@ucw.cz> Date: Sun, 9 Feb 2025 11:43:32 +0100 Subject: [PATCH] =?UTF-8?q?fixup!=20Diplomy/UI:=20"Smazat=20diplomy"=20lze?= =?UTF-8?q?=20i=20s=20nekorektn=C4=9B=20vypln=C4=9Bn=C3=BDm=20formul=C3=A1?= =?UTF-8?q?=C5=99em?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- mo/web/org_certs.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/mo/web/org_certs.py b/mo/web/org_certs.py index 18ab59c1..5ee6dd65 100644 --- a/mo/web/org_certs.py +++ b/mo/web/org_certs.py @@ -80,7 +80,7 @@ class CertSetForm(FlaskForm): delete = wtforms.SubmitField("Smazat diplomy") def osmo_validate(self, cset) -> bool: - if self.delete.data: + if (delete := getattr(self, 'delete')) is not None and delete.data: return True ok = True -- GitLab