Skip to content

Add federated groups #1739

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

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -556,6 +556,7 @@ class WebdavEntry constructor(
ShareType.EMAIL == shareType ||
ShareType.FEDERATED == shareType ||
ShareType.GROUP == shareType ||
ShareType.FEDERATED_GROUP == shareType ||
ShareType.ROOM == shareType
return if ((isSupportedShareType || displayName.isNotEmpty()) && userId.isNotEmpty()) {
ShareeUser(userId, displayName, shareType)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -73,6 +73,7 @@ public class GetShareesRemoteOperation extends RemoteOperation<ArrayList<JSONObj
private static final String NODE_USERS = "users";
private static final String NODE_GROUPS = "groups";
private static final String NODE_REMOTES = "remotes";
private static final String NODE_REMOTE_GROUPS = "remote_groups";
private static final String NODE_EMAILS = "emails";
private static final String NODE_ROOMS = "rooms";
private static final String NODE_CIRCLES = "circles";
Expand Down Expand Up @@ -138,6 +139,7 @@ protected RemoteOperationResult<ArrayList<JSONObject>> run(OwnCloudClient client
JSONArray respExactUsers = respExact.getJSONArray(NODE_USERS);
JSONArray respExactGroups = respExact.getJSONArray(NODE_GROUPS);
JSONArray respExactRemotes = respExact.getJSONArray(NODE_REMOTES);
JSONArray respExactRemoteGroups = respExact.getJSONArray(NODE_REMOTE_GROUPS);
JSONArray respExactCircles;
if (respExact.has(NODE_CIRCLES)) {
respExactCircles = respExact.getJSONArray(NODE_CIRCLES);
Expand All @@ -156,6 +158,7 @@ protected RemoteOperationResult<ArrayList<JSONObject>> run(OwnCloudClient client
JSONArray respPartialUsers = respData.getJSONArray(NODE_USERS);
JSONArray respPartialGroups = respData.getJSONArray(NODE_GROUPS);
JSONArray respPartialRemotes = respData.getJSONArray(NODE_REMOTES);
JSONArray respPartialRemoteGroups = respData.getJSONArray(NODE_REMOTE_GROUPS);
JSONArray respPartialCircles;

if (respData.has(NODE_CIRCLES)) {
Expand All @@ -165,23 +168,25 @@ protected RemoteOperationResult<ArrayList<JSONObject>> run(OwnCloudClient client
}

JSONArray respPartialRooms;

if (respData.has(NODE_ROOMS)) {
respPartialRooms = respData.getJSONArray(NODE_ROOMS);
} else {
respPartialRooms = new JSONArray();
}

JSONArray[] jsonResults = {
respExactUsers,
respExactGroups,
respExactRemotes,
respExactRemoteGroups,
respExactRooms,
respExactEmails,
respExactCircles,
respPartialUsers,
respPartialGroups,
respPartialRemotes,
respPartialRemoteGroups,
respPartialRooms,
respPartialCircles
};
Expand Down
Loading