mirror of
https://github.com/sqlmapproject/sqlmap.git
synced 2026-06-10 02:01:57 +00:00
Just in case patch (for --api)
This commit is contained in:
parent
36b660309b
commit
eba01ee74e
3 changed files with 5 additions and 5 deletions
|
|
@ -899,7 +899,7 @@ def clearColors(message):
|
|||
|
||||
retVal = message
|
||||
|
||||
if message:
|
||||
if isinstance(message, str):
|
||||
retVal = re.sub(r"\x1b\[[\d;]+m", "", message)
|
||||
|
||||
return retVal
|
||||
|
|
@ -923,7 +923,7 @@ def dataToStdout(data, forceOutput=False, bold=False, content_type=None, status=
|
|||
|
||||
try:
|
||||
if conf.get("api"):
|
||||
sys.stdout.write(message, status, content_type)
|
||||
sys.stdout.write(clearColors(message), status, content_type)
|
||||
else:
|
||||
sys.stdout.write(setColor(message, bold=bold))
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue