handling invalid referer url

Just ran into this strange referrer url in production ("https:/") and got back an error. Fixed to ignore such cases.