zjedi / hugo-scroll

Clean, responsive, single-page Hugo website theme.
https://themes.gohugo.io/hugo-scroll/
MIT License
256 stars 187 forks source link

BUG: `tel:` link is broken with the new dynamic contacts system #173

Closed filippofontana closed 3 months ago

filippofontana commented 3 months ago

Basically, when you insert urls dynamically with the Hugo template system, only http:, https: and mailto: are considered safe (see this page in the documentation for better context).

The solution is just to give the .url parameter to the safeURL function.

The issue is introduced in #170.

zjedi commented 3 months ago

Im ok with safeUrl, user is responsible for value parameters and they are defined in config file, no risk of injection from outside.

filippofontana commented 3 months ago

I'm going to submit a pull request then.