server/tags: fix tag category color validation
This was totally stupid...
This commit is contained in:
parent
a5b2d835d6
commit
4cd5b8c1ac
1 changed files with 1 additions and 1 deletions
|
@ -51,7 +51,7 @@ def update_category_name(category, name):
|
|||
def update_category_color(category, color):
|
||||
if not color:
|
||||
raise InvalidTagCategoryNameError('Color cannot be empty.')
|
||||
if not re.match(r'^#?[a-z]+$', color):
|
||||
if not re.match(r'^#?[0-9a-z]+$', color):
|
||||
raise InvalidTagCategoryNameError('Invalid color.')
|
||||
if util.value_exceeds_column_size(color, db.TagCategory.color):
|
||||
raise InvalidTagCategoryColorError('Color is too long.')
|
||||
|
|
Loading…
Reference in a new issue