We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent adfcd15 commit 19c3f52Copy full SHA for 19c3f52
1 file changed
lib/parse.js
@@ -34,10 +34,10 @@ function parse(input) {
34
35
// Have a boundary of input.length + 1 to access last pair inside the loop.
36
for (let i = 0; i < lastIndex + 1; i++) {
37
- let c = (i !== lastIndex && input.charCodeAt(i)) || 0;
+ let c = (i !== lastIndex && input.charCodeAt(i)) || -1;
38
39
// Handle '&' and end of line to pass the current values to result
40
- if (c === 38 || c === 0) {
+ if (c === 38 || c === -1) {
41
// Check if the current range consist of a single key
42
if (equalityIndex <= startingIndex) {
43
key = input.slice(startingIndex + 1, i);
0 commit comments