Got rid of the exit(0)