update observer pattern implementation