Skip to content

Commit

Permalink
Remove redundant dependencies
Browse files Browse the repository at this point in the history
  • Loading branch information
kibertoad authored and knagy committed Jul 15, 2024
1 parent fd8a607 commit 1340d06
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 6 deletions.
5 changes: 2 additions & 3 deletions lib/utils.js
Original file line number Diff line number Diff line change
@@ -1,10 +1,9 @@
'use strict';

const { types } = require('util');
const crypto = require('crypto');
const url = require('url');
const formatDate = require('dateformat');
const isNumber = require('is-number');
const isString = require('is-string');

const longDateRegExp = /^(\d{4})(\d{2})(\d{2})T(\d{2})(\d{2})(\d{2})Z$/;

Expand Down Expand Up @@ -119,7 +118,7 @@ class Utils {
}

static isValidHeaderValue(value) {
return isNumber(value) || isString(value);
return typeof value === 'number' || typeof value === 'string' || types.isStringObject(value);
}

static parseUrl(urlToParse, parseQueryString, slashesDenoteHost) {
Expand Down
4 changes: 1 addition & 3 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -55,8 +55,6 @@
"tape": "^4.17.0"
},
"dependencies": {
"dateformat": "4.6.3",
"is-number": "7.0.0",
"is-string": "1.0.7"
"dateformat": "4.6.3"
}
}

0 comments on commit 1340d06

Please sign in to comment.