Talk:App Object

From Hubitat Documentation
Jump to: navigation, search

The documentation page indicates that addChildDevice() has four arguments.

  • String namespace
  • String typeName
  • String deviceNetworkId
  • Map properties = [:])

Examples, like averageIlluminance.groovy suggest a fifth argument is required. From that file, see the "null" argument in the following example:

 addChildDevice("hubitat", "Virtual Illuminance Sensor", "AverageLux_${app.id}", null, [label: thisName, name: thisName])

-- Fixed in the documentation.