 
       dispositionName     = "filename=\"#{encodeURI(@currentFile.name)}\"; "
       dispositionEncoding = 'charset=utf-8'
-      disposition         = dispositionType + dispositionName + dispositionEncoding
-      cacheControl        = if (http.params.query.play and http.params.query.play == 'true') then 'public, must-revalidate, post-check=0, pre-check=0' else @cacheControl
-
+
+      http.response.setHeader 'Content-Type', fileRef.type
+      http.response.setHeader 'Content-Disposition', dispositionType + dispositionName + dispositionEncoding
+      http.response.setHeader 'Cache-Control', if (http.params.query.play and http.params.query.play == 'true') then 'public, must-revalidate, post-check=0, pre-check=0' else @cacheControl
+      http.response.setHeader 'Accept-Ranges', 'bytes'
 
       if http.request.headers.range
         partiral = true

          reqRange.start = start
          reqRange.end   = start + take

        if (@strict and not http.request.headers.range) or reqRange.start >= fileRef.size or reqRange.end > fileRef.size
          console.info "Meteor.Files Debugger: [download(#{http}, #{version})] [416] Content-Range is not specified!: #{fileRef.path}" if @debug
          http.response.writeHead 416,
            'Content-Range':        "bytes */#{fileRef.size}"
            'Pragma':               'public'
            'Expires':              -1
            'Cache-Control':        'public, must-revalidate, post-check=0, pre-check=0'
            'Accept-Ranges':        'bytes'
          http.response.end()
          return undefined
        else
          console.info "Meteor.Files Debugger: [download(#{http}, #{version})] [206]: #{fileRef.path}" if @debug
          
          console.log "[206]", {start: reqRange.start, end: reqRange.end}
          stream = fs.createReadStream fileRef.path, {start: reqRange.start, end: reqRange.end}
          http.response.writeHead 206, 
            'Content-Range':        "bytes #{reqRange.start}-#{reqRange.end}/#{fileRef.size}"
            'Cache-Control':        'no-cache'
            'Content-Type':         fileRef.type
            'Content-Encoding':     'binary'
            'Content-Disposition':  "attachment; filename=\"#{encodeURI(@currentFile.name)}\"; charset=utf-8"
            'Content-Length':       if reqRange.start == reqRange.end then 0 else (reqRange.end - reqRange.start + 1);
            'Accept-Ranges':        'bytes'
          stream.pipe http.response

      else
        console.info "Meteor.Files Debugger: [download(#{http}, #{version})] [200]: #{fileRef.path}" if @debug
        stream = fs.createReadStream fileRef.path
        http.response.writeHead 200, 
          'Content-Range':        "bytes 0-#{fileRef.size}/#{fileRef.size}"
          'Cache-Control':        cacheControl
          'Content-Type':         fileRef.type
          'Content-Disposition':  disposition
          'Content-Length':       fileRef.size
          'Accept-Ranges':        'bytes'
        stream.on 'open', ->
          stream.pipe http.response
        return undefined
  else
    undefined


          _storagePath:    self.storagePath
          _downloadRoute:  self.downloadRoute

        result._id = _newId if self.public

        
        if first
          fs.outputFileSync pathPart, binary, 'binary'
        else
          fs.appendFileSync pathPart, binary, 'binary'
        
        console.info "Meteor.Files Debugger: The part ##{part} of file #{fileName} (binary) was saved to #{pathPart}" if (chunksQty is currentChunk) and self.debug

        if last
          if partsQty > 1
