From 0fe63840854c185b40b0f788e227ef44ca5bb157 Mon Sep 17 00:00:00 2001 From: anoy Date: Sun, 4 Oct 2020 17:59:48 +0200 Subject: trim whitespaces in item titles Signed-off-by: anoy --- lib/Db/Item.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'lib') diff --git a/lib/Db/Item.php b/lib/Db/Item.php index 435fbdbfb..1619358ed 100644 --- a/lib/Db/Item.php +++ b/lib/Db/Item.php @@ -477,7 +477,7 @@ class Item extends Entity implements IAPI, \JsonSerializable public function setTitle(string $title = null): self { - $title = strip_tags($title); + $title = trim(strip_tags($title)); if ($this->title !== $title) { $this->title = $title; -- cgit v1.2.3