Socket connection now works

- Pairing a new device works

(I did a lot since the last commit)
This commit is contained in:
2021-11-14 01:42:21 +01:00
parent 28e85ea730
commit 19b7c05d75
72 changed files with 5861 additions and 23719 deletions

View File

@@ -12,7 +12,5 @@ export interface IUser extends Document {
salt: string,
type: UserType,
lastLogin: Date,
twoFASecret?: string,
brokerToken: string,
createdAt?: Date
twoFASecret?: string
}

View File

@@ -6,7 +6,6 @@ const schemaUser = new Schema({
salt: { type: String, required: true },
type: { type: String, required: true, default: 'user' }, // This could be user, admin, guest
twoFASecret: { type: String, required: false },
brokerToken: { type: String, required: true },
lastLogin: { type: Date, required: true, default: Date.now },
}, {
timestamps: {