summary refs log tree commit diff
path: root/src/db/schemas/user.js
diff options
context:
space:
mode:
Diffstat (limited to 'src/db/schemas/user.js')
-rw-r--r--src/db/schemas/user.js21
1 files changed, 21 insertions, 0 deletions
diff --git a/src/db/schemas/user.js b/src/db/schemas/user.js

index f8802d7..7680319 100644 --- a/src/db/schemas/user.js +++ b/src/db/schemas/user.js
@@ -84,6 +84,27 @@ export const userSchema = new Schema({ monitoredUsers: { type: [ObjectId], ref: 'users' + }, + balance: { + type: Number, + default: 0 + }, + spendHistory: { + type: [ObjectId], + ref: 'spendHistory' + }, + emergencyContacts: { + type: String + }, + medicalInfo: { + type: String + }, + location: { + // https://stackoverflow.com/a/27218808 + // Longtitute, Latitude info + type: [Number], + index: { type: '2dsphere', sparse: true }, + count: 2 } });