qorgh346 commited on
Commit
51b4d27
·
1 Parent(s): 92aef63

update loader module

Browse files
Files changed (1) hide show
  1. app.py +2 -2
app.py CHANGED
@@ -174,7 +174,7 @@ def main():
174
  print('file - type : ', file.type)
175
  if file.type == 'text/plain':
176
  #file is .txt
177
- raw_text += get_text_file(file)
178
  elif file.type in ['application/octet-stream', 'application/pdf']:
179
  #file is .pdf
180
  doc_list.extend(get_pdf_text(file))
@@ -183,7 +183,7 @@ def main():
183
  raw_text += get_csv_file(file)
184
  elif file.type == 'application/json':
185
  # file is .json
186
- raw_text += get_json_file(file)
187
  elif file.type == 'application/x-hwp':
188
  # file is .hwp
189
  raw_text += get_hwp_file(file)
 
174
  print('file - type : ', file.type)
175
  if file.type == 'text/plain':
176
  #file is .txt
177
+ doc_list.extend(get_text_file(file))
178
  elif file.type in ['application/octet-stream', 'application/pdf']:
179
  #file is .pdf
180
  doc_list.extend(get_pdf_text(file))
 
183
  raw_text += get_csv_file(file)
184
  elif file.type == 'application/json':
185
  # file is .json
186
+ doc_list.extend(get_json_file(file))
187
  elif file.type == 'application/x-hwp':
188
  # file is .hwp
189
  raw_text += get_hwp_file(file)