Skip to content

Commit

Permalink
Merge pull request #76 from Esukhia/fix-proofread
Browse files Browse the repository at this point in the history
fix(proofread
  • Loading branch information
kaldan007 authored Jan 15, 2022
2 parents 334b595 + 33ce3ad commit 0697a0b
Showing 1 changed file with 6 additions and 3 deletions.
9 changes: 6 additions & 3 deletions pedurma/proofreading.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,9 +10,12 @@ def get_note_page_img_link(text_id, pg_num, repo_path):


def get_note_page(text_id, cur_pg_num, repo_path=None):
manual_note = (
repo_path / text_id / "manual_notes" / f"{cur_pg_num:04}.txt"
).read_text(encoding="utf-8")
try:
manual_note = (
repo_path / text_id / "manual_notes" / f"{cur_pg_num:04}.txt"
).read_text(encoding="utf-8")
except Exception:
manual_note = ""
google_note = (
repo_path / text_id / "google_notes" / f"{cur_pg_num:04}.txt"
).read_text(encoding="utf-8")
Expand Down

0 comments on commit 0697a0b

Please sign in to comment.