Extract config into methods