fixed refresh error which occurs on reload