diff --git a/XenModel/Actions/Updates/DownloadUpdatesXmlAction.cs b/XenModel/Actions/Updates/DownloadUpdatesXmlAction.cs index d8b1b5d1e..a2e6d808d 100644 --- a/XenModel/Actions/Updates/DownloadUpdatesXmlAction.cs +++ b/XenModel/Actions/Updates/DownloadUpdatesXmlAction.cs @@ -343,11 +343,8 @@ namespace XenAdmin.Actions { var checkForUpdatesXml = new XmlDocument(); var checkForUpdatesUrl = XenAdminConfigManager.Provider.GetCustomUpdatesXmlLocation() ?? BrandManager.UpdatesUrl; - var authToken = XenAdminConfigManager.Provider.GetInternalStageAuthToken(); var uriBuilder = new UriBuilder(checkForUpdatesUrl); - uriBuilder.Query = AddAuthTokenToQueryString(authToken, uriBuilder.Query); - var uri = uriBuilder.Uri; if (uri.IsFile) { @@ -355,7 +352,9 @@ namespace XenAdmin.Actions } else { - + var authToken = XenAdminConfigManager.Provider.GetInternalStageAuthToken(); + uriBuilder.Query = AddAuthTokenToQueryString(authToken, uriBuilder.Query); + var proxy = XenAdminConfigManager.Provider.GetProxyFromSettings(Connection, false); using (var webClient = new WebClient())