Service heredity of contacts and contact groups

The problem is, that due to the following if condition, a service only
can inherit contact groups AND contacts:
if(temp_service->have_contact_groups == FALSE &&
temp_service->have_contacts == FALSE) {

But if you define a host with a contact and a contact group, and a
service with only a contact for example, only your service contact will
get an notification, but not the contact group that normally should be
inherited from the host.
If you want to stop the heredity you can add a contact or contact group
with notification interval none. I guess this is a better solution with
more flexibility for the admins