made the save-and-run thing into a separate function