fixing url generation