diff --git a/src/Kinds/K8sResource.php b/src/Kinds/K8sResource.php index cef93ecd..9b325342 100644 --- a/src/Kinds/K8sResource.php +++ b/src/Kinds/K8sResource.php @@ -98,7 +98,11 @@ public function exists(array $query = ['pretty' => 1]): bool try { $this->get($query); } catch (KubernetesAPIException $e) { - return false; + if ($e->getCode() === 404) { + return false; + } + + throw $e; } return true;