@tinypudding/puddy-lib
Advanced tools
Comparing version 1.1.14 to 1.1.15
module.exports = function (domain, httpResult = 'https') { | ||
// Domain Selected | ||
let domainSelected = null; | ||
// String | ||
if (typeof domain === "string") { | ||
domainSelected = domain; | ||
} | ||
// Nope | ||
else { | ||
domainSelected = require('./check_domain').get(domain); | ||
} | ||
// Domain | ||
if (typeof domainSelected === "string") { | ||
// Normal Domain | ||
if (!domain.startsWith('localhost:')) { return `${httpResult}://${domain}`; } | ||
if (!domainSelected.startsWith('localhost:')) { return `${httpResult}://${domainSelected}`; } | ||
// Localhost | ||
else { return `http://${domain}`; } | ||
else { return `http://${domainSelected}`; } | ||
@@ -12,0 +25,0 @@ } |
{ | ||
"name": "@tinypudding/puddy-lib", | ||
"version": "1.1.14", | ||
"version": "1.1.15", | ||
"description": "Essential codes to run the other repositories from the Tiny Pudding Account.", | ||
@@ -5,0 +5,0 @@ "main": "index.js", |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
63571
885