Cast allowed_hosts to string