Simplify code getting rid of service function, stop pyramid earlier.