Another round of DRYing up code.