Fix a variety of build errors

I still have to figure out how these crept in
Fix all unit tests

This involved changing one test, and changing one service method.