aboutsummaryrefslogtreecommitdiff
path: root/MediaBrowser.Server.Implementations/Udp
diff options
context:
space:
mode:
authorLuke Pulverenti <luke.pulverenti@gmail.com>2016-06-19 02:18:29 -0400
committerLuke Pulverenti <luke.pulverenti@gmail.com>2016-06-19 02:18:29 -0400
commit759f5a856064450acdb4c26839d6d890afb99a17 (patch)
treebc90bdc82a218644a1baa6762105afba6062b7ce /MediaBrowser.Server.Implementations/Udp
parent244531f9923bec28f4b1f6d55ad6858bd90f2135 (diff)
update task results
Diffstat (limited to 'MediaBrowser.Server.Implementations/Udp')
-rw-r--r--MediaBrowser.Server.Implementations/Udp/UdpServer.cs12
1 files changed, 6 insertions, 6 deletions
diff --git a/MediaBrowser.Server.Implementations/Udp/UdpServer.cs b/MediaBrowser.Server.Implementations/Udp/UdpServer.cs
index 40c4deb193..32992b9b27 100644
--- a/MediaBrowser.Server.Implementations/Udp/UdpServer.cs
+++ b/MediaBrowser.Server.Implementations/Udp/UdpServer.cs
@@ -96,20 +96,20 @@ namespace MediaBrowser.Server.Implementations.Udp
private async void RespondToV1Message(string endpoint, Encoding encoding)
{
- var localAddress = _appHost.LocalApiUrl;
+ var localUrl = await _appHost.GetLocalApiUrl().ConfigureAwait(false);
- if (!string.IsNullOrEmpty(localAddress))
+ if (!string.IsNullOrEmpty(localUrl))
{
// This is how we did the old v1 search, so need to strip off the protocol
- var index = localAddress.IndexOf("://", StringComparison.OrdinalIgnoreCase);
+ var index = localUrl.IndexOf("://", StringComparison.OrdinalIgnoreCase);
if (index != -1)
{
- localAddress = localAddress.Substring(index + 3);
+ localUrl = localUrl.Substring(index + 3);
}
// Send a response back with our ip address and port
- var response = String.Format("MediaBrowserServer|{0}", localAddress);
+ var response = String.Format("MediaBrowserServer|{0}", localUrl);
await SendAsync(Encoding.UTF8.GetBytes(response), endpoint);
}
@@ -121,7 +121,7 @@ namespace MediaBrowser.Server.Implementations.Udp
private async void RespondToV2Message(string endpoint, Encoding encoding)
{
- var localUrl = _appHost.LocalApiUrl;
+ var localUrl = await _appHost.GetLocalApiUrl().ConfigureAwait(false);
if (!string.IsNullOrEmpty(localUrl))
{