Modify refresh button's listener, remove useless code