I rechecked, the other methods are not fit for accept exit and quit and will raise error, that's why I add this function.