Clean unused code
Extract config class