src/server/middleware/cleanPathMiddleware.js
function cleanPathMiddleware(req, res, next) {
  req.cleanPath = req.path.replace(/\/$/, '');

  next();
}
function cleanPathMiddleware(req, res, next) {
  req.cleanPath = req.path.replace(/\/$/, '');

  next();
}
function cleanPathMiddleware ( req , res , next ) { req . cleanPath = req . path . replace ( / \/$ / , '' ) ; next ( ) ; }
Copyright 2017-present, Callstack.
All rights reserved.
Copyright 2017 - present Callstack . All rights reserved .