Changed getHost to really just do hostname extraction.