From 6cbc4536861215e3a6432d4e62f1b2f844f7160e Mon Sep 17 00:00:00 2001 From: Andrew Omondi Date: Fri, 19 Apr 2024 15:45:54 +0300 Subject: [PATCH] Throw error for not supported case --- src/Kiota.Builder/Plugins/PluginsGenerationService.cs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/Kiota.Builder/Plugins/PluginsGenerationService.cs b/src/Kiota.Builder/Plugins/PluginsGenerationService.cs index 667020730d..ed8c865230 100644 --- a/src/Kiota.Builder/Plugins/PluginsGenerationService.cs +++ b/src/Kiota.Builder/Plugins/PluginsGenerationService.cs @@ -69,10 +69,10 @@ public async Task GenerateManifestAsync(CancellationToken cancellationToken = de apiManifest.ApiDependencies.AddOrReplace(Configuration.ClientClassName, Configuration.ToApiDependency(OAIDocument.HashCode ?? string.Empty, TreeNode?.GetRequestInfo().ToDictionary(static x => x.Key, static x => x.Value) ?? [])); apiManifest.Write(writer); break; - case PluginType.OpenAI: - //TODO add support for OpenAI plugin type generation + case PluginType.OpenAI://TODO add support for OpenAI plugin type generation + // intentional drop to the default case default: - continue; + throw new NotImplementedException($"The {pluginType} plugin is not implemented."); } await writer.FlushAsync(cancellationToken).ConfigureAwait(false); }