Spaces:
Build error
Build error
Update app.py
Browse files
app.py
CHANGED
|
@@ -147,7 +147,8 @@ def render_message(history):
|
|
| 147 |
|
| 148 |
|
| 149 |
def escape_html(unsafe_text):
|
| 150 |
-
|
|
|
|
| 151 |
|
| 152 |
|
| 153 |
css="""
|
|
|
|
| 147 |
|
| 148 |
|
| 149 |
def escape_html(unsafe_text):
|
| 150 |
+
escaped_text = ''.join(f"&#{ord(char)};" if char != '\n' else '<br>' for char in unsafe_text)
|
| 151 |
+
return escaped_text
|
| 152 |
|
| 153 |
|
| 154 |
css="""
|