Fix bug that allowed to dismiss the loading modals