mirror of
https://github.com/cotes2020/jekyll-theme-chirpy.git
synced 2025-12-18 21:53:26 +00:00
fix: when the site.img_cdn is set to the local path, the preview-image path loses the baseurl
This commit is contained in:
@@ -92,7 +92,11 @@
|
||||
|
||||
<!-- Add CDN URL -->
|
||||
{% if site.img_cdn %}
|
||||
{% if site.img_cdn contains '//' %}
|
||||
{% assign _src_prefix = site.img_cdn %}
|
||||
{% else %}
|
||||
{% assign _src_prefix = site.img_cdn | relative_url %}
|
||||
{% endif %}
|
||||
{% else %}
|
||||
{% assign _src_prefix = site.baseurl %}
|
||||
{% endif %}
|
||||
|
||||
Reference in New Issue
Block a user