Added Logic for the modal to close it's self