Skip to content

Commit d75668c

Browse files
authored
Fix NRE in InProc store (#98)
Fixes #94
1 parent 6938c1b commit d75668c

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

src/SessionStateModule/SessionStateStoreProviderAsyncBase.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -205,7 +205,7 @@ public override void Initialize(string name, NameValueCollection config)
205205
// So we have inserted this setting here and it will apply to all providers that this async module can use.
206206

207207
// skipKeepAliveWhenUnused
208-
var skipKA = config["skipKeepAliveWhenUnused"];
208+
var skipKA = config?["skipKeepAliveWhenUnused"];
209209
if (skipKA != null && !bool.TryParse(skipKA, out _skipKeepAliveWhenUnused))
210210
{
211211
throw new ConfigurationErrorsException(string.Format(SR.Invalid_provider_option, "skipKeepAliveWhenUnused", name));
@@ -215,4 +215,4 @@ public override void Initialize(string name, NameValueCollection config)
215215
private bool _skipKeepAliveWhenUnused = false;
216216
internal bool SkipKeepAliveWhenUnused { get { return _skipKeepAliveWhenUnused; } }
217217
}
218-
}
218+
}

0 commit comments

Comments
 (0)