Skip to content

Commit

Permalink
Merge pull request #8241 from RocketChat/rodrigok-patch-2
Browse files Browse the repository at this point in the history
[FIX] Api groups.files is always returning empty
  • Loading branch information
rodrigok committed Sep 23, 2017
1 parent 6634cee commit f9d9538
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion packages/rocketchat-api/server/v1/groups.js
Original file line number Diff line number Diff line change
Expand Up @@ -161,7 +161,7 @@ RocketChat.API.v1.addRoute('groups.files', { authRequired: true }, {
const { offset, count } = this.getPaginationItems();
const { sort, fields, query } = this.parseJsonQuery();

const ourQuery = Object.assign({}, query, { rid: findResult._id });
const ourQuery = Object.assign({}, query, { rid: findResult.rid });

const files = RocketChat.models.Uploads.find(ourQuery, {
sort: sort ? sort : { name: 1 },
Expand Down

0 comments on commit f9d9538

Please sign in to comment.