fix bug not auto refresh.try catch email sending