prevent crashed on link not http/https protocol