       self.emitEvent 'prepare'
       return @result
 
-    manual: -> 
+    manual: ->
       self = @
       @result.start = ->
         self.emitEvent 'start'

  ###
  _handleUpload: if Meteor.isServer then (result, opts, cb) ->
    self = @

    try
      if opts.eof
        @_currentUploads[result._id].end -> bound ->
          self.emit '_finishUpload', result, opts, cb
          return
      else
        @_currentUploads[result._id].write opts.chunkId, new Buffer(opts.binData, 'base64'), cb
    catch e
      cb and cb e
    return

              self.emitEvent 'calculateStats'
            return
        else
          HTTP.call 'POST', "#{@collection.downloadRoute}/#{@collection.collectionName}/__upload", {
            content: opts.binData
            headers:
              'x-fileid':     opts.fileId
              'x-chunkid':    opts.chunkId
              'content-type': 'text/plain'
          }, (error, result) ->
            self.transferTime += (+new Date) - evt.data.start
            if error
              if "#{error}" is "Error: network"
