Skip to content

Commit

Permalink
chore: update dependencies
Browse files Browse the repository at this point in the history
  • Loading branch information
anonrig committed Dec 12, 2022
1 parent 1996905 commit 246237c
Show file tree
Hide file tree
Showing 6 changed files with 320 additions and 299 deletions.
2 changes: 1 addition & 1 deletion lib/encoding.js
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
* @returns {boolean}
*/
function is_c0_control_percent_encoded(code_point) {
return code_point <= 0x1F || code_point > 0x7E;
return code_point <= 0x1f || code_point > 0x7e;
}

const query_percent_encodes = {
Expand Down
7 changes: 3 additions & 4 deletions lib/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -75,10 +75,9 @@ function URLStateMachine(input, base = null, encodingOverride, stateOverride) {

// If input contains any leading or trailing C0 control or space, validation error.
// If input contains any ASCII tab or newline, validation error.
this.input = input.replace(
Regex.LEADING_TRAILING_C0_CONTROL_OR_SPACE,
"",
).replace(Regex.ASCII_TAB_OR_NEWLINE, "");
this.input = input
.replace(Regex.LEADING_TRAILING_C0_CONTROL_OR_SPACE, "")
.replace(Regex.ASCII_TAB_OR_NEWLINE, "");

this.base = base;
this.url = {
Expand Down
8 changes: 5 additions & 3 deletions lib/parser.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,11 @@
"use strict";
const { domainToASCII } = require("node:url");
const { FAILURE, Regex } = require("./constants");
const { is_ascii_hex, is_ascii_digit, utf8_percent_encode } = require(
"./string",
);
const {
is_ascii_hex,
is_ascii_digit,
utf8_percent_encode,
} = require("./string");
const { is_c0_control_percent_encoded } = require("./encoding");

/**
Expand Down
2 changes: 1 addition & 1 deletion lib/string.js
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ function is_single_dot_path_segment(input) {
* @returns {boolean}
*/
function is_ascii_alpha(code) {
return (code >= 0x41 && code <= 0x5A) || (code >= 0x61 && code <= 0x7A);
return (code >= 0x41 && code <= 0x5a) || (code >= 0x61 && code <= 0x7a);
}

/**
Expand Down
8 changes: 4 additions & 4 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -18,11 +18,11 @@
"author": "Yagiz Nizipli <[email protected]>",
"license": "MIT",
"devDependencies": {
"@types/node": "^18.7.21",
"@types/node": "^18.11.13",
"c8": "^7.12.0",
"cronometro": "^1.1.2",
"rome": "0.9.2-next",
"vitest": "^0.23.4",
"cronometro": "^1.1.5",
"rome": "11.0.0",
"vitest": "^0.25.7",
"whatwg-url": "^11.0.0"
},
"repository": {
Expand Down
Loading

0 comments on commit 246237c

Please sign in to comment.