detect null url, and also listen on https