fix except for prepare_url