Refactor constants

I think this is now ready to be merged.
Were these local edits? There doesn't appear to be a change here. If so, let's remove this from the commit.