code: function getVersion(req) {
     var version;
     if (!req.version) {
        if (req.headers && req.headers['accept-version']) {
           version = req.headers['accept-version'];
        }
     } else {
        version = String(req.version);
     }
     return version;
  }
docs: Gets the version of the application either from accept-version headers
  or req.version property