diff --git a/src/LibKubernetesGenerator/templates/Operations.cs.template b/src/LibKubernetesGenerator/templates/Operations.cs.template
index 2297b0d..94ad962 100644
--- a/src/LibKubernetesGenerator/templates/Operations.cs.template
+++ b/src/LibKubernetesGenerator/templates/Operations.cs.template
@@ -7,7 +7,7 @@
namespace k8s;
public partial class AbstractKubernetes : I{{name}}Operations
-{
+{
{{#apis}}
///
async Task"}}> I{{name}}Operations.{{GetMethodName operation "WithHttpMessagesAsync"}}(
@@ -17,7 +17,7 @@ public partial class AbstractKubernetes : I{{name}}Operations
IReadOnlyDictionary> customHeaders,
CancellationToken cancellationToken)
{
- var cts = CancellationTokenSource.CreateLinkedTokenSource(cancellationToken);
+ using var cts = CancellationTokenSource.CreateLinkedTokenSource(cancellationToken);
cts.CancelAfter(HttpClientTimeout);
{{#IfParamContains operation "watch"}}
if (watch == true)
@@ -58,13 +58,13 @@ public partial class AbstractKubernetes : I{{name}}Operations
{{#IfParamDoesNotContain operation "body"}}
var httpResponse = await SendRequest