Updated handling of popover