update popups code