mirror of
https://github.com/appwrite/appwrite.git
synced 2026-05-26 13:51:13 +00:00
refactor the class
This commit is contained in:
1 parent
a8f864a07d
commit
fa46f14092
4 files changed
+20
-9
No files matched your search
@@ -1,10 +1,10 @@
|
||||
<?php
|
||||
|
||||
namespace Appwrite\Statsd;
|
||||
namespace Appwrite\Stats;
|
||||
|
||||
use Utopia\App;
|
||||
|
||||
class Statsd
|
||||
class Stats
|
||||
{
|
||||
/**
|
||||
* @var array
|
||||
@@ -39,10 +39,20 @@ class Statsd
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param string $key
|
||||
*
|
||||
* @return mixed|null
|
||||
*/
|
||||
public function getParam(string $key)
|
||||
{
|
||||
return (isset($this->params[$key])) ? $this->params[$key] : null;
|
||||
}
|
||||
|
||||
/**
|
||||
* Submit data to StatsD.
|
||||
*/
|
||||
public function save(): void
|
||||
public function submit(): void
|
||||
{
|
||||
$projectId = $this->params['projectId'] ?? '';
|
||||
|
||||
Reference in new issue
Block a user