From 5936c6aba13e682a0386564bf5798c19dae35819 Mon Sep 17 00:00:00 2001 From: Cédric Bonhomme Date: Tue, 23 May 2017 21:36:12 +0200 Subject: tags are lowercase --- src/web/controllers/tag.py | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'src/web/controllers/tag.py') diff --git a/src/web/controllers/tag.py b/src/web/controllers/tag.py index a40387c9..203e9a7e 100644 --- a/src/web/controllers/tag.py +++ b/src/web/controllers/tag.py @@ -15,5 +15,9 @@ class BookmarkTagController(AbstractController): def count_by_href(self, **filters): return self._count_by(BookmarkTag.text, filters) + def create(self, **attrs): + attrs['text'] = attrs['text'].lower() + return super().create(**attrs) + def update(self, filters, attrs): return super().update(filters, attrs) -- cgit