Skip to content

Commit 2262685

Browse files
committed
Merge branch 'bugfix/host-ci-compatibility' into develop
After upgrading to C# 9.0, the Azure DevOps CI/CD Pipeline started failing with "rzc generate exited with code 2". This was resolved by removing C# 9.0 from the `OnTopic.AspNetcore.Mvc.Host` project. The CI/CD pipeline is fine with C# 9.0 inside .NET Core and .NET Standard class libraries. This isn't an issue here since the host project is purely for internal testing. In fact, while it's built by the CI/CD pipeline, it ends up being filtered out later in the build process since it won't build a NuGet package. That said, this issue will almost certainly be a bigger issue with the OnTopic Editor, which does rely on building a Razor Class Library. We'll need to cross that bridge when we come to it.
2 parents e9ccb06 + c8f9b4c commit 2262685

3 files changed

Lines changed: 3 additions & 4 deletions

File tree

OnTopic.AspNetCore.Mvc.Host/OnTopic.AspNetCore.Mvc.Host.csproj

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,9 @@
1-
<Project Sdk="Microsoft.NET.Sdk.Web">
1+
<Project Sdk="Microsoft.NET.Sdk.Web">
22

33
<PropertyGroup>
44
<TargetFramework>netcoreapp3.0</TargetFramework>
55
<UserSecretsId>62eb85bf-f802-4afd-8bec-3d344e1cfc79</UserSecretsId>
66
<IsPackable>false</IsPackable>
7-
<LangVersion>9.0</LangVersion>
87
</PropertyGroup>
98

109
<ItemGroup>

OnTopic.AspNetCore.Mvc.Host/Views/Layout/_Layout.cshtml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@
2626
<!-- /Page Header Area -->
2727

2828
<article itemscope itemtype="http://schema.org/WebPageElement" itemprop="mainContentOfPage" class="grid-container">
29-
<h1>@(Model.ContentType is "PageGroup"? "Overview" : Model.Title)</h1>
29+
<h1>@(Model.ContentType == "PageGroup"? "Overview" : Model.Title)</h1>
3030
<p class="subtitle">@Model.Subtitle</p>
3131
<section class="body">
3232
<partial name="_TopicAttributes" />

OnTopic.AspNetCore.Mvc.Host/Views/Shared/Components/PageLevelNavigation/Default.cshtml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
<h2>PageLevelNavigation</h2>
44
<ul>
5-
@if (Model.NavigationRoot is not null) {
5+
@if (Model.NavigationRoot != null) {
66
foreach (var topic in Model.NavigationRoot.Children) {
77
<li><a href="@topic.WebPath">@(topic.ShortTitle?? topic.Title)</a></li>
88
}

0 commit comments

Comments
 (0)