refactor weather