Add save on close