fixed the modal issues