simplified hide.bs.modal behaviour