This commit is contained in:
shimon
2023-09-26 10:47:00 +03:00
parent 6a377a4ef1
commit 8dbdd8a2fe
+3 -3
View File
@@ -136,12 +136,12 @@ class V20 extends Migration
* inf metric
*/
if (str_contains($from, 'total')) {
$result = $this->projectDB->findOne('stats', [
$query = $this->projectDB->findOne('stats', [
Query::equal('metric', [$from]),
Query::equal('period', ['1d']),
]);
var_dump($result);
$value = $result['value'] ?? 0;
var_dump($query);
$value = $query['value'] ?? 0;
var_dump($value);
$this->createInfMetric($to, $value);
}