Skip to content

Commit

Permalink
fix: TypeError when using frappe.throw() or frappe.msgprint() with li…
Browse files Browse the repository at this point in the history
…sts (#19255) (#19256)

Co-authored-by: Alfredo Altamirano <Ahuahuachi@users.noreply.github.com>



(cherry picked from commit ffe3ba1)

Co-authored-by: Alfredo Altamirano <8353891+Ahuahuachi@users.noreply.github.com>
  • Loading branch information
mergify[bot] and Ahuahuachi committed Dec 13, 2022
1 parent 3fa0207 commit 0748324
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion frappe/__init__.py
Expand Up @@ -454,7 +454,10 @@ def _raise_exception():
out.as_list = 1

if sys.stdin and sys.stdin.isatty():
msg = _strip_html_tags(out.message)
if out.as_list:
msg = [_strip_html_tags(msg) for msg in out.message]
else:
msg = _strip_html_tags(out.message)

if flags.print_messages and out.message:
print(f"Message: {_strip_html_tags(out.message)}")
Expand Down

0 comments on commit 0748324

Please sign in to comment.