fix bug for not reopen again