Simplify enable/disable config, move code around