Browse Source

Only check recent activity for all activities

Signed-off-by: Henrik Storch <henrik.storch@nextcloud.com>
Henrik Storch 3 years ago
parent
commit
e141716bfb
1 changed files with 2 additions and 2 deletions
  1. 2 2
      iOSClient/Activity/NCActivity.swift

+ 2 - 2
iOSClient/Activity/NCActivity.swift

@@ -432,7 +432,7 @@ extension NCActivity {
     func checkRecentActivity(disptachGroup: DispatchGroup) {
         let recentActivityId = NCManageDatabase.shared.getLatestActivityId(account: appDelegate.account)
 
-        guard recentActivityId > 0 else {
+        guard recentActivityId > 0, metadata == nil else {
             return self.loadActivity(idActivity: 0, disptachGroup: disptachGroup)
         }
 
@@ -441,7 +441,7 @@ extension NCActivity {
         NCCommunication.shared.getActivity(
             since: 0,
             limit: 1,
-            objectId: metadata?.fileId,
+            objectId: nil,
             objectType: objectType,
             previews: true) { (account, activities, errorCode, errorDescription) in
                 defer { disptachGroup.leave() }