started moving the code from the boardCtrl to a service