mirror of
https://github.com/appwrite/appwrite.git
synced 2026-05-26 13:51:13 +00:00
Fix upsert
This commit is contained in:
@@ -452,7 +452,7 @@ class StatsUsage extends Action
|
||||
return strcmp($a['time'], $b['time']);
|
||||
});
|
||||
|
||||
$dbForProject->createOrUpdateDocumentsWithIncrease('stats', 'value', $projectStats['stats']);
|
||||
$dbForProject->upsertDocumentsWithIncrease('stats', 'value', $projectStats['stats']);
|
||||
Console::success('Batch successfully written to DB');
|
||||
} catch (Throwable $e) {
|
||||
Console::error('Error processing stats: ' . $e->getMessage());
|
||||
@@ -532,7 +532,7 @@ class StatsUsage extends Action
|
||||
return strcmp($a['time'], $b['time']);
|
||||
});
|
||||
|
||||
$dbForLogs->createOrUpdateDocumentsWithIncrease(
|
||||
$dbForLogs->upsertDocumentsWithIncrease(
|
||||
'stats',
|
||||
'value',
|
||||
$this->statDocuments
|
||||
|
||||
Reference in New Issue
Block a user