refactor Observer.