mirror of
https://github.com/appwrite/appwrite.git
synced 2026-05-26 13:51:13 +00:00
chore: add group to usage event
This commit is contained in:
@@ -51,6 +51,22 @@ class Usage extends Event
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* Add group.
|
||||
*
|
||||
* @param string $key
|
||||
* @return self
|
||||
*/
|
||||
public function addGroup(string $key): self
|
||||
{
|
||||
|
||||
$this->metrics[] = [
|
||||
'group' => $key,
|
||||
];
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* Sends metrics to the usage worker.
|
||||
*
|
||||
|
||||
@@ -78,7 +78,6 @@ class UsageDump extends Action
|
||||
/**
|
||||
* End temp bug fallback
|
||||
*/
|
||||
|
||||
$numberOfKeys = !empty($stats['keys']) ? count($stats['keys']) : 0;
|
||||
$receivedAt = $stats['receivedAt'] ?? 'NONE';
|
||||
if ($numberOfKeys === 0) {
|
||||
|
||||
Reference in New Issue
Block a user