Loading src/main/java/com/nextcloud/android/sso/api/NextcloudAPI.java +8 −5 Original line number Diff line number Diff line Loading @@ -133,11 +133,14 @@ public class NextcloudAPI { Reader targetReader = new InputStreamReader(os)) { if (targetEntity != Void.class) { result = gson.fromJson(targetReader, targetEntity); /* if (result != null) { Log.d(TAG, result.toString()); if (result == null) { if (targetEntity == Object.class) { return (T) NOTHING; } else { throw new IllegalStateException("Could not instantiate \"" + targetEntity.toString() + "\", because response was null."); } } */ } else { result = (T) NOTHING; } Loading Loading @@ -165,7 +168,7 @@ public class NextcloudAPI { * @throws Exception or SSOException */ public Response performNetworkRequestV2(NextcloudRequest request) throws Exception { return networkRequest.performNetworkRequestV2(request, null); return networkRequest.performNetworkRequestV2(request, request.getBodyAsStream()); } protected Gson getGson() { Loading Loading
src/main/java/com/nextcloud/android/sso/api/NextcloudAPI.java +8 −5 Original line number Diff line number Diff line Loading @@ -133,11 +133,14 @@ public class NextcloudAPI { Reader targetReader = new InputStreamReader(os)) { if (targetEntity != Void.class) { result = gson.fromJson(targetReader, targetEntity); /* if (result != null) { Log.d(TAG, result.toString()); if (result == null) { if (targetEntity == Object.class) { return (T) NOTHING; } else { throw new IllegalStateException("Could not instantiate \"" + targetEntity.toString() + "\", because response was null."); } } */ } else { result = (T) NOTHING; } Loading Loading @@ -165,7 +168,7 @@ public class NextcloudAPI { * @throws Exception or SSOException */ public Response performNetworkRequestV2(NextcloudRequest request) throws Exception { return networkRequest.performNetworkRequestV2(request, null); return networkRequest.performNetworkRequestV2(request, request.getBodyAsStream()); } protected Gson getGson() { Loading