mirror of
https://github.com/ziirish/burp-ui.git
synced 2026-05-15 06:05:58 -06:00
fix empty arrays
This commit is contained in:
parent
2862242ae6
commit
1eef0c123a
4 changed files with 4 additions and 4 deletions
|
|
@ -30,6 +30,6 @@ indent_style = tab
|
|||
indent_style = space
|
||||
indent_size = 4
|
||||
|
||||
[.gitlab-ci.yml}]
|
||||
[.gitlab-ci.yml]
|
||||
indent_style = space
|
||||
indent_size = 2
|
||||
|
|
|
|||
|
|
@ -323,6 +323,8 @@ class BUIConfig(dict):
|
|||
"'{}': no such validator".format(cast)
|
||||
)
|
||||
return val
|
||||
if cast == 'force_list' and val is None:
|
||||
val = []
|
||||
ret = caster(val)
|
||||
# special case for boolean and integer, etc.
|
||||
if ret is None:
|
||||
|
|
|
|||
|
|
@ -26,7 +26,7 @@ def sanitize_string(string, strict=True, paranoid=False):
|
|||
else:
|
||||
import re
|
||||
ret = repr(string).replace('\\\\', '\\')
|
||||
ret = re.sub(r"^u?'(.*)'$", r"\1", ret)
|
||||
ret = re.sub(r"^u?(?P<quote>['\"])(.*)(?P=quote)$", r"\1", ret)
|
||||
return to_unicode(ret)
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -251,8 +251,6 @@ class BUIServer(Flask):
|
|||
)
|
||||
self.format_labels = []
|
||||
for format_label in format_labels:
|
||||
if not format_label:
|
||||
continue
|
||||
search = re.search(r'^s(?P<separator>.)(?P<regex>.*?)(?P=separator)(?P<replace>.*?)(?P=separator)$', format_label)
|
||||
if search:
|
||||
self.format_labels.append((search.group('regex'), search.group('replace')))
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue