Skip to content

Commit 47e8394

Browse files
authored
Update src/Microsoft.OpenApi.Readers/V2/OpenApiDocumentDeserializer.cs
1 parent f3c9141 commit 47e8394

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

src/Microsoft.OpenApi.Readers/V2/OpenApiDocumentDeserializer.cs

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -213,7 +213,11 @@ private static string BuildUrl(string scheme, string host, string basePath)
213213

214214
int? port = null;
215215

216+
#if NETSTANDARD2_1_OR_GREATER
216217
if (!String.IsNullOrEmpty(host) && host.Contains(':', StringComparison.OrdinalIgnoreCase))
218+
#else
219+
if (!String.IsNullOrEmpty(host) && host.Contains(':'))
220+
#endif
217221
{
218222
var pieces = host.Split(':');
219223
host = pieces.First();

0 commit comments

Comments
 (0)