mirror of
https://github.com/ail-project/ail-framework.git
synced 2024-11-30 01:37:17 +00:00
fix: [tag export] limit custom tag lenght
This commit is contained in:
parent
f91aba5f6f
commit
2c46c7f2ab
2 changed files with 7 additions and 0 deletions
|
@ -605,6 +605,10 @@ def disable_hive_auto_alert():
|
|||
@PasteSubmit.route("/PasteSubmit/add_push_tag")
|
||||
def add_push_tag():
|
||||
tag = request.args.get('tag')
|
||||
#limit tag length
|
||||
if len(tag) > 49:
|
||||
tag = tag[0:48]
|
||||
|
||||
r_serv_db.sadd('list_export_tags', tag)
|
||||
|
||||
to_return = {}
|
||||
|
|
|
@ -135,6 +135,9 @@ def mixUserName(supplied, extensive=False):
|
|||
|
||||
def save_tag_to_auto_push(list_tag):
|
||||
for tag in set(list_tag):
|
||||
#limit tag length
|
||||
if len(tag) > 49:
|
||||
tag = tag[0:48]
|
||||
r_serv_db.sadd('list_export_tags', tag)
|
||||
|
||||
# ============ ROUTES ============
|
||||
|
|
Loading…
Reference in a new issue