Skip to content

Commit

Permalink
Fix resume custom reference link bug (#2941)
Browse files Browse the repository at this point in the history
Hi,

I noticed an issue where the CV page fails to link to the correct custom
PDF when the `{% unless site.data.resume %}` block is executed in
`cv.liquid`. To resolve this, I updated the code to align its logic with
the else block to make it consistent.

---------

Co-authored-by: Maruan Al-Shedivat <[email protected]>
  • Loading branch information
rickyyuan07 and alshedivat authored Jan 14, 2025
1 parent 70c5ccf commit c2cc214
Showing 1 changed file with 8 additions and 3 deletions.
11 changes: 8 additions & 3 deletions _layouts/cv.liquid
Original file line number Diff line number Diff line change
Expand Up @@ -8,12 +8,17 @@ layout: default
{{ page.title }}
{% if page.cv_pdf %}
<a
href="{{ page.cv_pdf | prepend: 'assets/pdf/' | relative_url}}"
{% if page.cv_pdf contains '://' %}
href="{{ page.cv_pdf }}"
{% else %}
href="{{ page.cv_pdf | prepend: 'assets/pdf/' | relative_url }}"
{% endif %}
target="_blank"
rel="noopener noreferrer"
class="float-right"
><i class="fa-solid fa-file-pdf"></i
></a>
>
<i class="fa-solid fa-file-pdf"></i>
</a>
{% endif %}
</h1>
{% if page.description %}
Expand Down

0 comments on commit c2cc214

Please sign in to comment.