0

I am currently using express 4.0, which uses the node module "path-to-regexp"

path-to-regexp 0.1.7 doesn't allow zero or more path parameters

I want to upgrade path-to-regexp within express to version 1.2.1

Npm update has a depth paramater shown in the docs, but I don't want to update all of express' dependencies, just path-to-regexp.

I would also prefer to do it without forking express, and without manually altering express' package.json.

Community
  • 1
  • 1
Ryan White
  • 2,366
  • 1
  • 22
  • 34

1 Answers1

1

you can try

 cd node_modules/express
 npm install path-to-regexp@1.2.1
trquoccuong
  • 2,857
  • 2
  • 20
  • 26
  • Guess he will also need to run `npm shrinkwrap` to make sure that `path-to-regexp 1.2.1` is installed when he actually deploys his code to the server, assuming he is not tracking `node_modules` in a scm. – Swaraj Giri Jan 04 '16 at 11:00