Renamed the 'user_id' column into 'author' & added a ref to the 'users' schema
This commit is contained in:
parent
79d598002f
commit
075f8764d7
@ -36,8 +36,9 @@ const AddonSchema = new mongoose.Schema({
|
||||
type: Number,
|
||||
default: 0
|
||||
},
|
||||
user_id: { // The id of the author
|
||||
author: { // The author
|
||||
type: mongoose.mongo.ObjectId,
|
||||
ref: 'users',
|
||||
required: true
|
||||
},
|
||||
price: Number // The price needed to pay for the addon
|
||||
|
Loading…
x
Reference in New Issue
Block a user