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

query-string

Package Overview
Dependencies
Maintainers
1
Versions
82
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

query-string - npm Package Compare versions

Comparing version 2.4.1 to 2.4.2

6

index.js

@@ -21,4 +21,6 @@ 'use strict';

var parts = param.replace(/\+/g, ' ').split('=');
var key = parts[0];
var val = parts[1];
// Firefox (pre 40) decodes `%3D` to `=`
// https://github.com/sindresorhus/query-string/pull/37
var key = parts.shift();
var val = parts.length > 0 ? parts.join('=') : undefined;

@@ -25,0 +27,0 @@ key = decodeURIComponent(key);

{
"name": "query-string",
"version": "2.4.1",
"version": "2.4.2",
"description": "Parse and stringify URL query strings",

@@ -16,3 +16,3 @@ "license": "MIT",

"scripts": {
"test": "xo && mocha"
"test": "xo && ava"
},

@@ -41,5 +41,5 @@ "files": [

"devDependencies": {
"mocha": "*",
"ava": "*",
"xo": "*"
}
}

@@ -16,3 +16,3 @@ # query-string [![Build Status](https://travis-ci.org/sindresorhus/query-string.svg?branch=master)](https://travis-ci.org/sindresorhus/query-string)

```js
var queryString = require('query-string');
const queryString = require('query-string');

@@ -22,3 +22,3 @@ console.log(location.search);

var parsed = queryString.parse(location.search);
const parsed = queryString.parse(location.search);
console.log(parsed);

@@ -30,3 +30,3 @@ //=> {foo: 'bar'}

var parsedHash = queryString.parse(location.hash);
const parsedHash = queryString.parse(location.hash);
console.log(parsedHash);

@@ -33,0 +33,0 @@ //=> {token: 'bada55cafe'}

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