Skip to content

Commit

Permalink
Fix broken build + increment patch version
Browse files Browse the repository at this point in the history
  • Loading branch information
domaindrivendev committed Sep 22, 2021
1 parent 7c1ec87 commit cbb3912
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/Directory.Build.props
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
<PublishRepositoryUrl>true</PublishRepositoryUrl>
<RepositoryType>git</RepositoryType>
<RepositoryUrl>https://github.com/domaindrivendev/Swashbuckle.AspNetCore.git</RepositoryUrl>
<VersionPrefix>6.2.1</VersionPrefix>
<VersionPrefix>6.2.2</VersionPrefix>
</PropertyGroup>

<PropertyGroup Condition="'$(APPVEYOR)'=='True' AND '$(APPVEYOR_REPO_TAG)'=='false'">
Expand Down
Original file line number Diff line number Diff line change
@@ -1,8 +1,13 @@
using System;
using Microsoft.AspNetCore.Hosting;
using Microsoft.Extensions.DependencyInjection;
using Microsoft.Extensions.Options;
using Swashbuckle.AspNetCore.SwaggerUI;

#if NETSTANDARD2_0
using IWebHostEnvironment = Microsoft.AspNetCore.Hosting.IHostingEnvironment;
#endif

namespace Microsoft.AspNetCore.Builder
{
public static class SwaggerUIBuilderExtensions
Expand Down Expand Up @@ -33,7 +38,6 @@ public static IApplicationBuilder UseSwaggerUI(this IApplicationBuilder app, Swa
if (options.ConfigObject.Urls == null)
{
var hostingEnv = app.ApplicationServices.GetRequiredService<IWebHostEnvironment>();

options.ConfigObject.Urls = new[] { new UrlDescriptor { Name = $"{hostingEnv.ApplicationName} v1", Url = "v1/swagger.json" } };
}

Expand Down

0 comments on commit cbb3912

Please sign in to comment.