@taiger-common/model 1.0.45 → 1.0.46
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/model/User.js +2 -2
- package/dist/esm/model/User.js +2 -2
- package/dist/umd/index.js +1 -1
- package/package.json +1 -1
package/dist/cjs/model/User.js
CHANGED
|
@@ -4,7 +4,7 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
4
4
|
};
|
|
5
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
6
|
var mongoose_1 = require("mongoose");
|
|
7
|
-
var
|
|
7
|
+
var validator_1 = __importDefault(require("validator"));
|
|
8
8
|
var core_1 = require("@taiger-common/core");
|
|
9
9
|
var Program_1 = require("./Program");
|
|
10
10
|
var ManagerType = {
|
|
@@ -45,7 +45,7 @@ var userSchema = new mongoose_1.Schema({
|
|
|
45
45
|
type: String,
|
|
46
46
|
unique: true,
|
|
47
47
|
lowercase: true,
|
|
48
|
-
validate: [
|
|
48
|
+
validate: [validator_1.default.isEmail, 'Invalid email address']
|
|
49
49
|
},
|
|
50
50
|
pictureUrl: {
|
|
51
51
|
type: String
|
package/dist/esm/model/User.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { Schema } from 'mongoose';
|
|
2
|
-
import
|
|
2
|
+
import validator from 'validator';
|
|
3
3
|
import { DocumentStatusType } from '@taiger-common/core';
|
|
4
4
|
import { PROGRAM_SUBJECT_KEYS } from './Program';
|
|
5
5
|
var ManagerType = {
|
|
@@ -40,7 +40,7 @@ var userSchema = new Schema({
|
|
|
40
40
|
type: String,
|
|
41
41
|
unique: true,
|
|
42
42
|
lowercase: true,
|
|
43
|
-
validate: [isEmail, 'Invalid email address']
|
|
43
|
+
validate: [validator.isEmail, 'Invalid email address']
|
|
44
44
|
},
|
|
45
45
|
pictureUrl: {
|
|
46
46
|
type: String
|