@riocrypto/common-server 1.0.2731 → 1.0.2733

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.
@@ -168,6 +168,12 @@ const buildAuth = (mongoose) => {
168
168
  });
169
169
  AuthSchema.pre("save", function (done) {
170
170
  return __awaiter(this, void 0, void 0, function* () {
171
+ if (this.isModified("email")) {
172
+ const email = this.get("email");
173
+ if (email) {
174
+ this.set("email", email.toLowerCase());
175
+ }
176
+ }
171
177
  if (this.isModified("password")) {
172
178
  const hashed = yield password_1.Password.toHash(this.get("password"));
173
179
  this.set("password", hashed);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@riocrypto/common-server",
3
- "version": "1.0.2731",
3
+ "version": "1.0.2733",
4
4
  "description": "",
5
5
  "main": "./build/index.js",
6
6
  "types": "./build/index.d.ts",