Deleting modals once they are no longer needed.  Fixes #119