Added a default cookie if there is error.