[Fix] can't redirect correctly after deleting a chart while there is any unsaved chart