fix url generation