Fixing bug when there is no icon on head

When there is no icon on the <head> the script would try to include a `null` image.

Requesting `mywebsite.com/section/hello/world` would result in the script trying to include `mywebsite.com/section/hello/null` as a image.

I understand that this library is about managing the icon, but it should not fail while doing it.

Also changed the errors to include the original message, that should help debugging.