Skip to content

Commit

Permalink
upgrade ip-regex to 5.0.0 (#51)
Browse files Browse the repository at this point in the history
Co-authored-by: Andrew Sharpe <[email protected]>
  • Loading branch information
asharpe and Andrew Sharpe authored Jun 26, 2024
1 parent 9b48bb7 commit a5f636f
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
"author": "MajorTom327",
"license": "MIT",
"peerDependencies": {
"ip-regex": "^4.2.0",
"ip-regex": "^5.0.0",
"rambda": "^9.0.1",
"spf-parse": "^1.0.4"
},
Expand All @@ -30,7 +30,7 @@
"@rollup/plugin-typescript": "^11.1.6",
"@types/ip-regex": "^4.1.1",
"@types/node": "^18.14.5",
"ip-regex": "^4.2.0",
"ip-regex": "^5.0.0",
"rambda": "^9.0.1",
"rollup": "^4.9.6",
"spf-parse": "^1.0.4",
Expand Down
4 changes: 2 additions & 2 deletions src/SpfInspector.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import * as dns from "dns";
import SpfParser from "spf-parse";
import { Record, SpfMechanism, SpfType } from "./Record";
import { v4 as ipV4, v6 as ipV6 } from "ip-regex";
import ipRegex from 'ip-regex';
import { Report } from "./Report";
import { InspecterError } from "./Inspecter";
import {
Expand Down Expand Up @@ -40,7 +40,7 @@ type Status = {
} & Search;

const isRawIp = (domain: string): boolean =>
ipV4().test(domain) || ipV6().test(domain);
ipRegex.v4().test(domain) || ipRegex.v6().test(domain);

const SpfInspector = (
domain: string,
Expand Down

0 comments on commit a5f636f

Please sign in to comment.