Closed peterschewe closed 1 year ago
This PR corrects the URL of the share image.
By default the asset urls come from Contentful without prototcol – e.g.:
//images.ctfassets.net.../share_image.jpg
But the real absolute URL including prototol is needed.
Otherwise the image will be resolved like this:
https://www.yourdomain.com//images.ctfassets.net.../share_image.jpg
In addition, the code snippet was moved to a util because we already use the pattern (Hugo function absURL + protocol) in other places.
Kudos, SonarCloud Quality Gate passed!
0 Bugs 0 Vulnerabilities 0 Security Hotspots 0 Code Smells
No Coverage information 0.0% Duplication
This PR corrects the URL of the share image.
By default the asset urls come from Contentful without prototcol – e.g.:
But the real absolute URL including prototol is needed.
Otherwise the image will be resolved like this:
In addition, the code snippet was moved to a util because we already use the pattern (Hugo function absURL + protocol) in other places.