mirror of
https://github.com/MODSetter/SurfSense.git
synced 2026-04-26 01:06:23 +02:00
fix: Markdown & Text files as default support.
This commit is contained in:
parent
a1742f26de
commit
21fb231683
2 changed files with 4 additions and 5 deletions
|
|
@ -138,8 +138,8 @@ async def process_file_in_background(
|
|||
session: AsyncSession
|
||||
):
|
||||
try:
|
||||
# Check if the file is a markdown file
|
||||
if filename.lower().endswith(('.md', '.markdown')):
|
||||
# Check if the file is a markdown or text file
|
||||
if filename.lower().endswith(('.md', '.markdown', '.txt')):
|
||||
# For markdown files, read the content directly
|
||||
with open(file_path, 'r', encoding='utf-8') as f:
|
||||
markdown_content = f.read()
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue