diff --git a/src/Microsoft.AspNet.Server.Kestrel/ServerInformation.cs b/src/Microsoft.AspNet.Server.Kestrel/ServerInformation.cs index 6205e4c2c1..ec80e002a1 100644 --- a/src/Microsoft.AspNet.Server.Kestrel/ServerInformation.cs +++ b/src/Microsoft.AspNet.Server.Kestrel/ServerInformation.cs @@ -17,8 +17,8 @@ namespace Microsoft.AspNet.Server.Kestrel public void Initialize(IConfiguration configuration) { - string urls; - if (!configuration.TryGet("server.urls", out urls)) + var urls = configuration["server.urls"]; + if (!string.IsNullOrEmpty(urls)) { urls = "http://+:5000/"; }