diff options
author | Marvin Borner | 2018-10-30 19:39:59 +0100 |
---|---|---|
committer | Marvin Borner | 2018-10-30 19:39:59 +0100 |
commit | f585fea9f15958260e6af29feb1e9cc72bde64e3 (patch) | |
tree | 553b944b1e65755a0961d63e1bd745d2401dd152 /src/models/posts.model.js | |
parent | 94dcb2a098e978ff56eb711ae3c0b7abcb8d69ca (diff) |
Added user object in post answer
Diffstat (limited to 'src/models/posts.model.js')
-rw-r--r-- | src/models/posts.model.js | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/models/posts.model.js b/src/models/posts.model.js index e46117c..a48d2f6 100644 --- a/src/models/posts.model.js +++ b/src/models/posts.model.js @@ -6,6 +6,10 @@ const DataTypes = Sequelize.DataTypes; module.exports = function (app) { const sequelizeClient = app.get('sequelizeClient'); const posts = sequelizeClient.define('posts', { + userId: { + type: DataTypes.INTEGER, + allowNull: false + }, text: { type: DataTypes.STRING, allowNull: false |