http-hash
http-hash copied to clipboard
add backtrace feature for splat matching
Add backtrace feature for splat matching to support case like follows:
// when route set like follows
hash.set('/a/b/c', routeHandlerABC);
hash.set('/a/b/*', routeHandlerABStar);
// /a/b/c/d could match /a/b/*
var res = hash.get('/a/b/c/d');
assert.strictEqual(res.handler, routeHandlerABStar);