瀏覽代碼

Tags can have slashes, too, as a treat

Getty Ritter 4 年之前
父節點
當前提交
7847fb41b3
共有 1 個文件被更改,包括 1 次插入1 次删除
  1. 1 1
      lc/model.py

+ 1 - 1
lc/model.py

@@ -224,7 +224,7 @@ class Tag(Model):
 
     @staticmethod
     def is_valid_tag_name(tag_name: str) -> bool:
-        return all((c.isalnum() for c in tag_name))
+        return all((c.isalnum() or c == '/' for c in tag_name))
 
     @staticmethod
     def get_or_create_tag(user: User, tag_name: str) -> 'Tag':