     # Changes is the queue of operations, it contains
     # files that are being downloaded, and files to upload.
     changes: async.queue (task, callback) ->
-        #console.log task.operation, task.file
         deviceName = config.getDeviceName()
 
         if task.operation in [

            filesystem.watchingLocked = true
            callbackOrig = callback
            callback = (err, res) ->
                #console.log 'done'
                filesystem.watchingLocked = false
                callbackOrig err, res
        #else
        #    callback_orig = callback
        #    callback = (err, res) ->
        #        console.log 'done'
        #        callback_orig err, res

        switch task.operation
            when 'post'

                filesystem.applyFileDBChanges true, callback
            when 'reDownload'
                filesystem.applyFileDBChanges false, callback
            when 'applyFileDBChanges'
                filesystem.applyFileDBChanges false, callback
            else
                # 'applyFolderDBChanges'
                filesystem.applyFolderDBChanges callback
