Fixed minor bug when pressing cancel with a delete.