       traverse = (reference, actual) ->
         for k of reference
           continue if k[0] == '_'
-          if not actual[k]?._timestamp? or actual[k]._timestamp > lastBootstrap
+          if not actual[k]?._timestamp? or actual[k]._timestamp < lastBootstrap
             _tasks.push({device: deviceId, name : 'refreshObject', objectName : reference[k]._path})
           else
             traverse(reference[k], actual[k])

        projection[path + '_timestamp'] = 1

    db.devicesCollection.findOne({'_id' : deviceId}, projection, (err, device) ->
      lastBootstrap ?= device?._lastBootstrap
      _tasks = []


            nextTask(currentRequest)
          )
        else
          throw new Error('Unknown task status')
    )
  )

