Socket
Socket
Sign inDemoInstall

legit

Package Overview
Dependencies
0
Maintainers
1
Versions
17
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

Comparing version 1.0.4 to 1.0.5

2

package.json
{
"name": "legit",
"version": "1.0.4",
"version": "1.0.5",
"description": "Check that email addresses are really able to accept emails by pinging the DNS and checking for active MX records.",

@@ -5,0 +5,0 @@ "main": "./src/index.js",

@@ -1,9 +0,9 @@

const dns = require("dns");
const dns = require('dns');
const validateEmailAddress = emailAddress => {
return new Promise((resolve, reject) => {
const splitEmail = emailAddress.split("@");
const splitEmail = emailAddress.split('@');
dns.resolveMx(splitEmail[1], (err, mx) => {
if (typeof mx != "undefined") {
if (typeof mx != 'undefined') {
mx

@@ -13,3 +13,3 @@ ? resolve({ isValid: true, mxArray: mx })

} else {
reject(err);
reject(new Error(err));
}

@@ -16,0 +16,0 @@ });

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc