Skip to content

Commit

Permalink
Don't adapt sorting on the client side
Browse files Browse the repository at this point in the history
  • Loading branch information
mrsimpson committed Nov 24, 2017
1 parent 00e4bb5 commit 9b71b62
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -15,11 +15,7 @@ Template.permissions.helpers({
},

settingPermissions() {
return SettingPermissions.find({}, {
sort: {
_id: 1
}
});
return SettingPermissions.find();
},

hasPermission() {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ Meteor.methods({
const records = RocketChat.models.Permissions.find({
level: permissionLevel.SETTING,
groupPermissionId: {$exists: true} //filter group permissions themselves, as they are being assigned implicitly
}, {}, {sort: {group: 1, section: 1}}).fetch();
}, {}, {sort: {group: 1, section: 1, sorter: 1}}).fetch();

if (updatedAt instanceof Date) {
return {
Expand Down

0 comments on commit 9b71b62

Please sign in to comment.