Skip to content
Snippets Groups Projects
Verified Commit fb98d9cd authored by ynerant's avatar ynerant
Browse files

Fix one more error in alias autocompletion


Signed-off-by: ynerant's avatarYohann D'ANELLO <ynerant@crans.org>
parent 0dd3da5c
No related branches found
No related tags found
2 merge requests!177Corrections de bugs,!176Corrections de bugs
Pipeline #9074 passed with stages
in 15 minutes and 26 seconds
......@@ -138,7 +138,7 @@ class ConsumerViewSet(ReadOnlyProtectedModelViewSet):
try:
re.compile(alias)
valid_regex = True
except re.error:
except (re.error, TypeError):
valid_regex = False
suffix = '__iregex' if valid_regex else '__istartswith'
alias_prefix = '^' if valid_regex else ''
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment