I knew there was a DRY way to do it...