diff options
| author | Phlogi <Phlogi@users.noreply.github.com> | 2019-03-24 17:11:21 +0100 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2019-03-24 17:11:21 +0100 |
| commit | d18252542d81e1c279b10af0198be30a8b94edea (patch) | |
| tree | 50fe868d804a03b0c041c7d25784361fb2960d57 | |
| parent | 030fcaac156e9d75d4e7e84b0bea1291b91c0079 (diff) | |
Also add the WAN switch to the public system info.
| -rw-r--r-- | Emby.Server.Implementations/ApplicationHost.cs | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/Emby.Server.Implementations/ApplicationHost.cs b/Emby.Server.Implementations/ApplicationHost.cs index fea23a3d7..a20838daf 100644 --- a/Emby.Server.Implementations/ApplicationHost.cs +++ b/Emby.Server.Implementations/ApplicationHost.cs @@ -1375,7 +1375,7 @@ namespace Emby.Server.Implementations var wanAddress = ServerConfigurationManager.Configuration.WanDdns; if (string.IsNullOrEmpty(wanAddress)){ - var wanAddress = await GetWanApiUrl(cancellationToken).ConfigureAwait(false); + wanAddress = await GetWanApiUrl(cancellationToken).ConfigureAwait(false); } return new SystemInfo @@ -1426,7 +1426,11 @@ namespace Emby.Server.Implementations public async Task<PublicSystemInfo> GetPublicSystemInfo(CancellationToken cancellationToken) { var localAddress = await GetLocalApiUrl(cancellationToken).ConfigureAwait(false); - var wanAddress = await GetWanApiUrl(cancellationToken).ConfigureAwait(false); + var wanAddress = ServerConfigurationManager.Configuration.WanDdns; + + if (string.IsNullOrEmpty(wanAddress)){ + wanAddress = await GetWanApiUrl(cancellationToken).ConfigureAwait(false); + } return new PublicSystemInfo { Version = ApplicationVersion, |
