mirror of
https://github.com/actualbudget/actual.git
synced 2026-04-27 17:48:17 -05:00
🔧 Prevent metadata.json update if the sync time value is the same (#3398)
* prevent metadata.json update if the sync time value is the same as the saved one * release notes
This commit is contained in:
@@ -768,11 +768,15 @@ async function _fullSync(
|
||||
),
|
||||
);
|
||||
} else {
|
||||
// All synced up, store the current time as a simple optimization
|
||||
// for the next sync
|
||||
await prefs.savePrefs({
|
||||
lastSyncedTimestamp: getClock().timestamp.toString(),
|
||||
});
|
||||
// All synced up, store the current time as a simple optimization for the next sync
|
||||
const requiresUpdate =
|
||||
getClock().timestamp.toString() !== lastSyncedTimestamp;
|
||||
|
||||
if (requiresUpdate) {
|
||||
await prefs.savePrefs({
|
||||
lastSyncedTimestamp: getClock().timestamp.toString(),
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
return receivedMessages;
|
||||
|
||||
6
upcoming-release-notes/3398.md
Normal file
6
upcoming-release-notes/3398.md
Normal file
@@ -0,0 +1,6 @@
|
||||
---
|
||||
category: Maintenance
|
||||
authors: [MikesGlitch]
|
||||
---
|
||||
|
||||
Prevent sync from saving to metadata.json unnecessarily
|
||||
Reference in New Issue
Block a user