               else
                 syncState.refreshAttributes[attrName].add(currentPath)
 
-          if declareAttributeValues.value?
+          if declareAttributeValues?.value?
             syncState.spv.set(currentPath, declareAttributeValues.value)
 
     for child of children

    currentPath = paths[0]
    children = {}
    declareTimestamp = 0
    declareAttributeTimestamps = {}
    declareAttributeValues = {}

    currentTimestamp = 0
    currentAttributes = null

    switch (if currentPath[0] != '*' then currentPath[0] else leafParam[0])
      when 'Reboot'
        if currentPath.length == 1
          if declareAttributeValues?.value?
            syncState.reboot = +(new Date(declareAttributeValues.value[0]))
      when 'FactoryReset'
        if currentPath.length == 1
          if declareAttributeValues?.value?
            syncState.factoryReset = +(new Date(declareAttributeValues.value[0]))
      when 'Tags'
        if currentPath.length == 2 and currentPath.wildcard == 0 and declareAttributeValues?.value?
