Skip to content

Commit 9dba5fd

Browse files
committed
Changed configuration of Lazy to make it threadsafe
1 parent 0d68e70 commit 9dba5fd

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/Microsoft.OpenApi/Validations/ValidationRuleSet.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ public static ValidationRuleSet DefaultRuleSet
3030
{
3131
if (_defaultRuleSet == null)
3232
{
33-
_defaultRuleSet = new Lazy<ValidationRuleSet>(() => BuildDefaultRuleSet(), isThreadSafe: false).Value;
33+
_defaultRuleSet = new Lazy<ValidationRuleSet>(() => BuildDefaultRuleSet(), isThreadSafe: true).Value;
3434
}
3535

3636
return _defaultRuleSet;

0 commit comments

Comments
 (0)