change the exiting rules
change the exiting rules