From 16c2ab05e57559ce66b08c59bbb2edd073f77849 Mon Sep 17 00:00:00 2001 From: BonfaceKilz Date: Tue, 24 May 2022 12:52:44 +0300 Subject: Strip data before storing it --- wqflask/wqflask/metadata_edits.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/wqflask/wqflask/metadata_edits.py b/wqflask/wqflask/metadata_edits.py index 74f1cd15..1f86eaa9 100644 --- a/wqflask/wqflask/metadata_edits.py +++ b/wqflask/wqflask/metadata_edits.py @@ -830,7 +830,7 @@ def approve_case_attribute_data(): "INSERT INTO CaseAttribute " "(Name, Description) VALUES " "(%s, %s)", - (data.get("name"), data.get("description"),)) + (data.get("name").strip(), data.get("description").strip(),)) cursor.execute( "UPDATE caseattributes_audit SET " "status = 'approved' WHERE id = %s", -- cgit v1.2.3