restaf has a method to get the root object of a service added via restaf. This returns a null if service does not exist. It makes for better flow of code if addServices checked for existence of the service and either return the existing one or create a new one.
restaf has a method to get the root object of a service added via restaf. This returns a null if service does not exist. It makes for better flow of code if addServices checked for existence of the service and either return the existing one or create a new one.