Fix source_code function with the dynamic answer class.

This commit is contained in:
Oleksandr Kozachuk 2023-10-20 14:02:09 +02:00 committed by juk0de
parent ee363d9894
commit 8f95a362d2

View File

@ -51,7 +51,7 @@ def source_code(text: str, include_delims: bool = False) -> list[str]:
code_lines: list[str] = []
in_code_block = False
for line in text.split('\n'):
for line in str(text).split('\n'):
if line.strip().startswith('```'):
if include_delims:
code_lines.append(line)