@helpfulhuman/router-kit
Advanced tools
Comparing version 1.0.4 to 1.0.5
@@ -62,6 +62,11 @@ import pathToRegex from 'path-to-regexp'; | ||
var callNext = function () { | ||
var args = [], len = arguments.length; | ||
while ( len-- ) args[ len ] = arguments[ len ]; | ||
// Filter falsey values | ||
var argCount = args.filter(function (item) { return !!item; }).length; | ||
// Find the next middleware to call in the stack (if any) | ||
var next = mw.shift(); | ||
// Attempt to invoke the next middleware | ||
if (arguments.length === 0 && next) { | ||
if (argCount === 0 && next) { | ||
try { | ||
@@ -68,0 +73,0 @@ return next(context, callNext); |
@@ -68,6 +68,11 @@ 'use strict'; | ||
var callNext = function () { | ||
var args = [], len = arguments.length; | ||
while ( len-- ) args[ len ] = arguments[ len ]; | ||
// Filter falsey values | ||
var argCount = args.filter(function (item) { return !!item; }).length; | ||
// Find the next middleware to call in the stack (if any) | ||
var next = mw.shift(); | ||
// Attempt to invoke the next middleware | ||
if (arguments.length === 0 && next) { | ||
if (argCount === 0 && next) { | ||
try { | ||
@@ -74,0 +79,0 @@ return next(context, callNext); |
{ | ||
"name": "@helpfulhuman/router-kit", | ||
"version": "1.0.4", | ||
"version": "1.0.5", | ||
"description": "Simple library for building custom frontend routing solutions for single page applications.", | ||
@@ -5,0 +5,0 @@ "main": "dist/index.js", |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
13357
347