auth-code-pablo
Advanced tools
Comparing version 1.0.0 to 2.1.0
{ | ||
"name": "auth-code-pablo", | ||
"version": "1.0.0", | ||
"version": "2.1.0", | ||
"description": "Simple authentication for API key validation", | ||
@@ -5,0 +5,0 @@ "main": "src/index.js", |
@@ -9,2 +9,3 @@ // src/index.js | ||
apiKey = key; | ||
console.clear(); | ||
console.log(`🔑 API Key set to: ${apiKey}`); | ||
@@ -14,2 +15,3 @@ }, | ||
if (!apiKey) { | ||
console.clear(); | ||
console.error('❌ API Key is missing. Please set your API Key using auth.key() before starting.'); | ||
@@ -19,2 +21,3 @@ return; | ||
console.clear(); | ||
console.log('🚀 Starting API Key validation...'); | ||
@@ -27,2 +30,3 @@ | ||
if (active) { | ||
console.clear(); | ||
console.log('✅ API Key is valid! Access granted.'); | ||
@@ -34,5 +38,7 @@ await new Promise(resolve => setTimeout(resolve, 5000)); // Optional delay | ||
} else { | ||
console.clear(); | ||
console.log(`❌ Access denied. Invalid API Key. Reason: ${reason}`); | ||
} | ||
} catch (error) { | ||
console.clear(); | ||
console.error('⚠️ Error during API Key validation:', error.message); | ||
@@ -39,0 +45,0 @@ } |
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
5277
37