got it to stop running when finished