From 9e9baba65986a4b3071ea1ddc61eb7f05688e4e1 Mon Sep 17 00:00:00 2001 From: Panu Horsmalahti Date: Thu, 25 Nov 2021 09:40:02 +0200 Subject: [PATCH] Use PartialDeep for patch type. Signed-off-by: Panu Horsmalahti --- src/common/k8s-api/kube-api.ts | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/common/k8s-api/kube-api.ts b/src/common/k8s-api/kube-api.ts index 33cecf3db1..beb4227a18 100644 --- a/src/common/k8s-api/kube-api.ts +++ b/src/common/k8s-api/kube-api.ts @@ -37,6 +37,7 @@ import type { RequestInit } from "node-fetch"; import AbortController from "abort-controller"; import { Agent, AgentOptions } from "https"; import type { Patch } from "rfc6902"; +import type { PartialDeep } from "type-fest"; export interface IKubeApiOptions { /** @@ -526,7 +527,7 @@ export class KubeApi { return parsed; } - async patch(desc: ResourceDescriptor, data?: Partial | Patch, strategy: KubeApiPatchType = "strategic"): Promise { + async patch(desc: ResourceDescriptor, data?: PartialDeep | Patch, strategy: KubeApiPatchType = "strategic"): Promise { await this.checkPreferredVersion(); const apiUrl = this.getUrl(desc);