Add logic to config controller