Merge user list of response

This commit is contained in:
Matias De lellis
2020-06-17 00:14:24 -03:00
parent 76b8b0dd99
commit bb3ea8ddaf

View File

@@ -164,12 +164,16 @@ Notes.prototype = {
var self = this; var self = this;
$.get(OC.linkToOCS('apps/files_sharing/api/v1/', 1) + 'sharees', { $.get(OC.linkToOCS('apps/files_sharing/api/v1/', 1) + 'sharees', {
format: 'json', format: 'json',
itemType: '1' perPage: 50,
itemType: 1
}).done(function (shares) { }).done(function (shares) {
var users = []; var users = [];
$.each(shares.ocs.data.exact.users, function(index, user) { $.each(shares.ocs.data.exact.users, function(index, user) {
users.push(user.value.shareWith); users.push(user.value.shareWith);
}); });
$.each(shares.ocs.data.users, function(index, user) {
users.push(user.value.shareWith);
});
self._usersSharing = users; self._usersSharing = users;
}).fail(function () { }).fail(function () {
console.error("Could not get users to share."); console.error("Could not get users to share.");