Spaces:
Sleeping
Sleeping
Update app_logic.py
Browse files- app_logic.py +2 -2
app_logic.py
CHANGED
@@ -61,7 +61,7 @@ def load_token_from_image_and_set_env(image_pil_object: Image.Image, password: s
|
|
61 |
def process_commented_markdown(lines):
|
62 |
|
63 |
"""Process a commented markdown string by stripping '# ' from each line if any line starts with '# # Space:'."""
|
64 |
-
if any(line.strip().startswith("#
|
65 |
print("FOUND ALT MARKDOWN")
|
66 |
cleaned_lines = [line.lstrip("# ") for line in lines]
|
67 |
return cleaned_lines
|
@@ -76,7 +76,7 @@ def parse_markdown(markdown_input):
|
|
76 |
in_file_definition = False; in_code_block = False
|
77 |
lines = markdown_input.strip().split("\n")
|
78 |
lines = process_commented_markdown(lines)
|
79 |
-
print(lines)
|
80 |
for line_content_orig in lines:
|
81 |
line_content_stripped = line_content_orig.strip()
|
82 |
if line_content_stripped.startswith("### File:"):
|
|
|
61 |
def process_commented_markdown(lines):
|
62 |
|
63 |
"""Process a commented markdown string by stripping '# ' from each line if any line starts with '# # Space:'."""
|
64 |
+
if any(line.strip().startswith(("# # Space:", "# Space:")) for line in lines):
|
65 |
print("FOUND ALT MARKDOWN")
|
66 |
cleaned_lines = [line.lstrip("# ") for line in lines]
|
67 |
return cleaned_lines
|
|
|
76 |
in_file_definition = False; in_code_block = False
|
77 |
lines = markdown_input.strip().split("\n")
|
78 |
lines = process_commented_markdown(lines)
|
79 |
+
#print(lines)
|
80 |
for line_content_orig in lines:
|
81 |
line_content_stripped = line_content_orig.strip()
|
82 |
if line_content_stripped.startswith("### File:"):
|