[API] Fix bugs
This commit is contained in:
parent
88e5a18509
commit
e31eec542f
5 changed files with 5 additions and 15 deletions
|
|
@ -77,7 +77,7 @@ module.exports = (params, user) =>
|
|||
}
|
||||
|
||||
// メッセージを作成
|
||||
const inserted = await Message.insert({
|
||||
const message = await Message.insert({
|
||||
created_at: new Date(),
|
||||
file_id: file ? file._id : undefined,
|
||||
recipient_id: recipient._id,
|
||||
|
|
@ -86,8 +86,6 @@ module.exports = (params, user) =>
|
|||
is_read: false
|
||||
});
|
||||
|
||||
const message = inserted.ops[0];
|
||||
|
||||
// Serialize
|
||||
const messageObj = await serialize(message);
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue