diff --git a/app/controllers/api/health.php b/app/controllers/api/health.php index dc1113ed67..1bc0b0ee81 100644 --- a/app/controllers/api/health.php +++ b/app/controllers/api/health.php @@ -110,9 +110,6 @@ App::get('/v1/health/db') ]; foreach ($configs as $key => $config) { - if (!is_array($config)) { - continue; - } foreach ($config as $database) { try { $adapter = new DatabasePool($pools->get($database)); @@ -123,8 +120,6 @@ App::get('/v1/health/db') $output[] = new Document([ 'name' => $key . " ($database)", 'status' => 'pass', - 'checkStart' => $checkStart, - 'now' => \microtime(true), 'ping' => \round((\microtime(true) - $checkStart) * 1000) ]); } else { @@ -177,9 +172,6 @@ App::get('/v1/health/cache') ]; foreach ($configs as $key => $config) { - if (!is_array($config)) { - continue; - } foreach ($config as $cache) { try { $adapter = new CachePool($pools->get($cache)); @@ -240,9 +232,6 @@ App::get('/v1/health/pubsub') ]; foreach ($configs as $key => $config) { - if (!is_array($config)) { - continue; - } foreach ($config as $pubsub) { try { $adapter = new PubSubPool($pools->get($pubsub)); diff --git a/composer.lock b/composer.lock index b3678d693e..bfebc67918 100644 --- a/composer.lock +++ b/composer.lock @@ -6663,16 +6663,16 @@ }, { "name": "phpunit/phpunit", - "version": "9.6.29", + "version": "9.6.30", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/phpunit.git", - "reference": "9ecfec57835a5581bc888ea7e13b51eb55ab9dd3" + "reference": "b69489b312503bf8fa6d75a76916919d7d2fa6d4" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/9ecfec57835a5581bc888ea7e13b51eb55ab9dd3", - "reference": "9ecfec57835a5581bc888ea7e13b51eb55ab9dd3", + "url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/b69489b312503bf8fa6d75a76916919d7d2fa6d4", + "reference": "b69489b312503bf8fa6d75a76916919d7d2fa6d4", "shasum": "" }, "require": { @@ -6746,7 +6746,7 @@ "support": { "issues": "https://github.com/sebastianbergmann/phpunit/issues", "security": "https://github.com/sebastianbergmann/phpunit/security/policy", - "source": "https://github.com/sebastianbergmann/phpunit/tree/9.6.29" + "source": "https://github.com/sebastianbergmann/phpunit/tree/9.6.30" }, "funding": [ { @@ -6770,7 +6770,7 @@ "type": "tidelift" } ], - "time": "2025-09-24T06:29:11+00:00" + "time": "2025-12-01T07:35:08+00:00" }, { "name": "psr/cache", diff --git a/tests/e2e/Services/Health/HealthCustomServerTest.php b/tests/e2e/Services/Health/HealthCustomServerTest.php index 3a25cd0d3c..4b7062dc22 100644 --- a/tests/e2e/Services/Health/HealthCustomServerTest.php +++ b/tests/e2e/Services/Health/HealthCustomServerTest.php @@ -40,8 +40,7 @@ class HealthCustomServerTest extends Scope 'content-type' => 'application/json', 'x-appwrite-project' => $this->getProject()['$id'], ], $this->getHeaders()), []); - var_dump($response['body']); - + $this->assertEquals(200, $response['headers']['status-code']); $this->assertEquals('pass', $response['body']['statuses'][0]['status']); $this->assertIsInt($response['body']['statuses'][0]['ping']);