Adding the steps to close out the edit mode