diff --git a/src/RazorBlade.Library/RazorTemplate.cs b/src/RazorBlade.Library/RazorTemplate.cs index c5ca3e9..e64bcef 100644 --- a/src/RazorBlade.Library/RazorTemplate.cs +++ b/src/RazorBlade.Library/RazorTemplate.cs @@ -182,7 +182,7 @@ protected internal virtual void Write(IEncodedContent? content) [EditorBrowsable(EditorBrowsableState.Never)] protected internal void DefineSection(string name, Func action) { -#if NETCOREAPP +#if NET6_0_OR_GREATER if (!_sections.TryAdd(name, action)) throw new InvalidOperationException($"Section '{name}' is already defined."); #else