Skip to content

Commit

Permalink
Fix empty file name if file name start with bracket
Browse files Browse the repository at this point in the history
  • Loading branch information
kongwoojin committed Aug 31, 2022
1 parent 90edd59 commit bdf4a77
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion cse_crawler.py
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ async def cse_article_parser(url: str):
for file in files:
file_uri = file.select_one("a")["href"]
file_name = file.select_one("a").get_text()
file_name = re.sub("\[.*]", "", file_name).strip()
file_name = re.sub("\[File.*]", "", file_name).strip()

file_dic = {
"file_uri": file_uri,
Expand Down

0 comments on commit bdf4a77

Please sign in to comment.