Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

2way-router

Package Overview
Dependencies
Maintainers
1
Versions
12
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

2way-router - npm Package Compare versions

Comparing version 1.2.5 to 1.3.0

7

lib/RouteParams.js

@@ -80,6 +80,7 @@ /**

RouteParams.prototype.merge = function () {
var result = {}, name;
var result = {}, values;
for (name in this.queryParams) {
if (this.queryParams.hasOwnProperty(name)) {
result[name] = this.queryParams[name];
if (this.queryParams.hasOwnProperty(name) && this.queryParams[name].length > 0) {
values = this.queryParams[name];
result[name] = values[values.length - 1];
}

@@ -86,0 +87,0 @@ }

{
"name": "2way-router",
"version": "1.2.5",
"version": "1.3.0",
"description": "2-way router",

@@ -5,0 +5,0 @@ "main": "index.js",

@@ -117,5 +117,5 @@ /*global describe, xdescribe, it, expect*/

expectRouteWithParams(router.findRoute("/news/page/205/?a=1&a=3&b=2&c"), routeA, {
a: [ '1', '3' ],
b: [ '2' ],
c: [ '' ],
a: '3',
b: '2',
c: '',
page: 205

@@ -122,0 +122,0 @@ }, done);

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc