Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update stylecop.json schema to have correct default for headerDecoration. #3842

Merged
merged 2 commits into from
May 22, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -116,7 +116,7 @@ protected internal DocumentationSettings()
{
this.companyName = DefaultCompanyName;
this.copyrightText = DefaultCopyrightText;
this.headerDecoration = null;
this.headerDecoration = string.Empty;
this.variables = ImmutableDictionary<string, string>.Empty;
this.xmlHeader = true;

Expand Down Expand Up @@ -267,7 +267,7 @@ protected internal DocumentationSettings(JsonObject documentationSettingsObject,
this.documentPrivateFields = documentPrivateFields.GetValueOrDefault(false);
this.companyName = companyName ?? DefaultCompanyName;
this.copyrightText = copyrightText ?? DefaultCopyrightText;
this.headerDecoration = headerDecoration;
this.headerDecoration = headerDecoration ?? string.Empty;
this.variables = variables?.ToImmutable() ?? ImmutableDictionary<string, string>.Empty;
this.xmlHeader = xmlHeader.GetValueOrDefault(true);
this.fileNamingConvention = fileNamingConvention.GetValueOrDefault(FileNamingConvention.StyleCop);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -263,7 +263,7 @@
"headerDecoration": {
"type": "string",
"description": "The text used as decoration for the copyright header comment.",
"default": null
"default": ""
},
"fileNamingConvention": {
"type": "string",
Expand Down