Call to a member function getService() on null