Fixed bug with multiple popups opened at the same time