Refactors the gauges controller