Refactor configuration class.