simplify refresh script