Trying to fix the modal problem