-
Notifications
You must be signed in to change notification settings - Fork 10.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[FEATURE] Rest API upload file returns message object #13821
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@knrt10 I think the description of the issue says to return the message object and not the upload object. 🤔
@MarcosSpessatto hmm, my bad. Let me fix this |
@MarcosSpessatto updated the PR. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
app/api/server/v1/rooms.js
Outdated
}); | ||
|
||
return API.v1.success(); | ||
return API.v1.success({ file: Messages.getMessageByFileIdAndUsername(fileData._id, this.userId) }); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can you change file
to message
?
No problem, let me update tests |
@MarcosSpessatto tests updated, also a small fix was made when |
@knrt10 amazing. Thanks so much. 🥇 |
No problem, happy to contribute |
Closes #13808
Docs PR
@sampaiodiego @tassoevan would you please review.