Skip to content

Commit

Permalink
use long for lastGiven
Browse files Browse the repository at this point in the history
Signed-off-by: alperozturk <[email protected]>
  • Loading branch information
alperozturk96 committed Feb 20, 2025
1 parent 2c72914 commit 86363c1
Showing 1 changed file with 4 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ public class GetActivitiesRemoteOperation extends RemoteOperation {

private static final String NODE_DATA = "data";

private int lastGiven = -1;
private long lastGiven = -1;

private long fileId = -1;

Expand All @@ -65,7 +65,7 @@ public GetActivitiesRemoteOperation(long fileId) {
this.fileId = fileId;
}

public GetActivitiesRemoteOperation(long fileId, int lastGiven) {
public GetActivitiesRemoteOperation(long fileId, long lastGiven) {
this.fileId = fileId;
this.lastGiven = lastGiven;
}
Expand Down Expand Up @@ -114,7 +114,7 @@ public RemoteOperationResult run(NextcloudClient client) {
if (isSuccess(status)) {
String nextPageHeader = get.getResponseHeader("X-Activity-Last-Given");
if (nextPageHeader != null) {
lastGiven = Integer.parseInt(nextPageHeader);
lastGiven = Long.parseLong(nextPageHeader);
} else {
lastGiven = -1;
}
Expand Down Expand Up @@ -185,7 +185,7 @@ protected RemoteOperationResult run(OwnCloudClient client) {

Header nextPageHeader = get.getResponseHeader("X-Activity-Last-Given");
if (nextPageHeader != null) {
lastGiven = Integer.parseInt(nextPageHeader.getValue());
lastGiven = Long.parseLong(nextPageHeader.getValue());
} else {
lastGiven = -1;
}
Expand Down

0 comments on commit 86363c1

Please sign in to comment.