Update editor config to not force private constants to be named _camelCase
This commit is contained in:
@@ -25,16 +25,22 @@ dotnet_naming_rule.private_members_with_underscore.severity = suggestion
|
||||
|
||||
dotnet_naming_symbols.private_fields.applicable_kinds = field
|
||||
dotnet_naming_symbols.private_fields.applicable_accessibilities = private
|
||||
dotnet_naming_symbols.private_fields.required_modifiers = abstract,async,readonly,static # all except const
|
||||
|
||||
dotnet_naming_style.prefix_underscore.capitalization = camel_case
|
||||
dotnet_naming_style.prefix_underscore.required_prefix = _
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
# https://github.com/MicrosoftDocs/visualstudio-docs/blob/master/docs/ide/editorconfig-code-style-settings-reference.md
|
||||
[*.cs]
|
||||
csharp_style_var_for_built_in_types = true:suggestion
|
||||
csharp_style_var_when_type_is_apparent = true:suggestion
|
||||
csharp_style_var_elsewhere = true:suggestion
|
||||
csharp_prefer_braces = false : none
|
||||
csharp_prefer_braces = false : none
|
||||
|
||||
[*.{js,less}]
|
||||
trim_trailing_whitespace = false
|
||||
[*.{js,less}]
|
||||
trim_trailing_whitespace = false
|
||||
|
||||
@@ -9,7 +9,7 @@ namespace Umbraco.Web.Models.PublishedContent
|
||||
public class HttpContextVariationContextAccessor : IVariationContextAccessor
|
||||
{
|
||||
private readonly IRequestCache _requestCache;
|
||||
private const string _contextKey = "Umbraco.Web.Models.PublishedContent.DefaultVariationContextAccessor";
|
||||
private const string ContextKey = "Umbraco.Web.Models.PublishedContent.DefaultVariationContextAccessor";
|
||||
|
||||
/// <summary>
|
||||
/// Initializes a new instance of the <see cref="HttpContextVariationContextAccessor"/> class.
|
||||
@@ -22,8 +22,8 @@ namespace Umbraco.Web.Models.PublishedContent
|
||||
/// <inheritdoc />
|
||||
public VariationContext VariationContext
|
||||
{
|
||||
get => (VariationContext) _requestCache.Get(_contextKey);
|
||||
set => _requestCache.Set(_contextKey, value);
|
||||
get => (VariationContext) _requestCache.Get(ContextKey);
|
||||
set => _requestCache.Set(ContextKey, value);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user