fixed bug when modals where misplaced