docs: function serveFile(req, res, stats, filePath, cache) {
    const stream = fs.createReadStream(filePath);
  
    stream.on('error', function(err) {
      const error = new Error('Error reading file');
  
      res.writeHead(500, {'Content-Type': 'application/json'});
      res.end(JSON.stringify(error));
    });
  
    if (path.extname(filePath) === '.gz') {
      res.writeHead(200, {
        'Content-Type': mime.getType(filePath.replace('.gz', '')),
        'ETag': createServerEtag(stats.ino, stats.mtime),
        'Cache-Control': cache,
        'Content-Encoding': 'gzip',
        'Content-Length': stats.size
      });
  
    } else {
      res.writeHead(200, {
        'Content-Type': mime.getType(filePath),
        'ETag': createServerEtag(stats.ino, stats.mtime),
        'Cache-Control': cache,
        'Content-Length': stats.size
      });
    }
  
    stream.pipe(res);
  }