Fixed some warnings in ObjectService