Added hostname check