Fix NullPointerException with config