gcf-api-router
Advanced tools
Comparing version 1.0.0 to 1.0.1
@@ -87,5 +87,3 @@ const pathToRegexp = require('path-to-regexp'); | ||
function findRequestHandlers(req, routes) { | ||
let path = req.params[0].charAt(0) !== '/' | ||
? '/' + req.params[0] | ||
: req.params[0]; | ||
let path = req.path || '/'; | ||
for (let route of routes) { | ||
@@ -92,0 +90,0 @@ let match = route.pathRegex.exec(path); |
{ | ||
"name": "gcf-api-router", | ||
"version": "1.0.0", | ||
"version": "1.0.1", | ||
"description": "Express-style API router for Google Cloud Functions", | ||
@@ -5,0 +5,0 @@ "main": "index.js", |
11840
102