Skip to content

Commit 226534f

Browse files
committed
Fixing null reference
1 parent 42eb514 commit 226534f

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/WebJobs.Script/DependencyInjection/ScriptStartupTypeLocator.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -340,7 +340,7 @@ void CollectError(Type extensionType, Version minimumVersion, ExtensionStartupTy
340340
private bool IsDotnetIsolatedApp(IEnumerable<FunctionMetadata> functions, IEnvironment environment)
341341
{
342342
string workerRuntime = Utility.GetWorkerRuntime(functions, environment);
343-
return workerRuntime.Equals(RpcWorkerConstants.DotNetIsolatedLanguageWorkerName, StringComparison.OrdinalIgnoreCase);
343+
return workerRuntime?.Equals(RpcWorkerConstants.DotNetIsolatedLanguageWorkerName, StringComparison.OrdinalIgnoreCase) ?? false;
344344
}
345345

346346
private class TypeNameEqualityComparer : IEqualityComparer<Type>

0 commit comments

Comments
 (0)