Skip to content

Commit

Permalink
Fix non-existing font import
Browse files Browse the repository at this point in the history
  • Loading branch information
tudoramariei committed Jan 27, 2024
1 parent f26b393 commit ff47b65
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion backend/donations/pdf.py
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,8 @@


abs_path = os.path.abspath(os.path.join(os.path.dirname(__file__), os.path.pardir))
font_path = abs_path + "/static/font/opensans.ttf"
# TODO: we might need to rethink this; we should not hardcode the path to static_extras
font_path = abs_path + "/static_extras/font/opensans.ttf"
pdfmetrics.registerFont(TTFont("OpenSans", font_path))

default_font_size = 15
Expand Down

0 comments on commit ff47b65

Please sign in to comment.