diff --git a/src/Infrastructure/BotSharp.Core/Instructs/Services/InstructService.Execute.cs b/src/Infrastructure/BotSharp.Core/Instructs/Services/InstructService.Execute.cs index cceb7bba..c22ac27c 100644 --- a/src/Infrastructure/BotSharp.Core/Instructs/Services/InstructService.Execute.cs +++ b/src/Infrastructure/BotSharp.Core/Instructs/Services/InstructService.Execute.cs @@ -103,10 +103,10 @@ public partial class InstructService } IFileLlmProcessor? fileProcessor = null; - if (!files.IsNullOrEmpty() && !string.IsNullOrEmpty(fileOptions?.FileLlmProcessorProvider)) + if (!files.IsNullOrEmpty() && fileOptions != null) { fileProcessor = _services.GetServices() - .FirstOrDefault(x => x.Provider.IsEqualTo(fileOptions?.FileLlmProcessorProvider)); + .FirstOrDefault(x => x.Provider.IsEqualTo(fileOptions.FileLlmProcessorProvider)); } if (fileProcessor != null)