Fixed exiting procedure and tested so we are ready to publish