idea-toolbox
Advanced tools
Comparing version 6.5.1 to 6.5.2
@@ -29,2 +29,6 @@ /** | ||
/** | ||
* Check whether the user's attributes are valid. | ||
*/ | ||
validate(): string[]; | ||
/** | ||
* Whether the user is part of the administrators group. | ||
@@ -31,0 +35,0 @@ */ |
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
exports.CognitoUser = void 0; | ||
const utils_1 = require("./utils"); | ||
/** | ||
@@ -23,2 +24,13 @@ * A user stored in a Cognito User Pool. | ||
/** | ||
* Check whether the user's attributes are valid. | ||
*/ | ||
validate() { | ||
const e = []; | ||
if ((0, utils_1.isEmpty)(this.name)) | ||
e.push('name'); | ||
if ((0, utils_1.isEmpty)(this.email, 'email')) | ||
e.push('email'); | ||
return e; | ||
} | ||
/** | ||
* Whether the user is part of the administrators group. | ||
@@ -25,0 +37,0 @@ */ |
{ | ||
"name": "idea-toolbox", | ||
"version": "6.5.1", | ||
"version": "6.5.2", | ||
"description": "IDEA's utility functions", | ||
@@ -5,0 +5,0 @@ "main": "dist/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
467516
13861