acecalisto3 commited on
Commit
127fc81
·
verified ·
1 Parent(s): 9fa7b65

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +10 -10
app.py CHANGED
@@ -224,16 +224,16 @@ class FileProcessor:
224
  try:
225
  with open(filepath, 'r', encoding='utf-8', errors='ignore') as f:
226
  content = f.read()
227
- if content.strip():
228
- results.append({
229
- "source": "file",
230
- "filename": filename,
231
- "content": content,
232
- "timestamp": datetime.now().isoformat()
233
- })
234
- except Exception as e:
235
- logger.error(f"Error reading file {filename}: {str(e)}")
236
- return results
237
 
238
  def _process_single_file(self, file) -> List[Dict]:
239
  try:
 
224
  try:
225
  with open(filepath, 'r', encoding='utf-8', errors='ignore') as f:
226
  content = f.read()
227
+ if content.strip():
228
+ results.append({
229
+ "source": "file",
230
+ "filename": filename,
231
+ "content": content,
232
+ "timestamp": datetime.now().isoformat()
233
+ })
234
+ except Exception as e:
235
+ logger.error(f"Error reading file {filename}: {str(e)}")
236
+ return results
237
 
238
  def _process_single_file(self, file) -> List[Dict]:
239
  try: