fix cancel bugs