update method
Implementation
Future<void> update(String id, Map<String, dynamic> updates) async {
final document = collection[id];
if (document != null) {
final now = HarnUtils.generateTimeStamp();
Task task = Task("update", () async {
collection[id] = {
...convertDateTimeToString(document),
...convertDateTimeToString(updates),
'updatedAt': now.toIso8601String(),
};
});
harnCollectionQueue.enqueue(task);
_notifyDocumentUpdated(id);
await _saveCollection();
}
}