Call to a member function requirePartnerPermission on a non-object