From c53cd6facd347af4dcb9a9db45c41013e53cc8f7 Mon Sep 17 00:00:00 2001 From: Andreas Linde Date: Fri, 19 Sep 2014 15:03:08 +0200 Subject: [PATCH] Request update of a specific version Even though the UI showed the newest version that the device can install, the download request always triggered downloading the latest version. This commit fixes this bug. --- Classes/BITUpdateManager.m | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Classes/BITUpdateManager.m b/Classes/BITUpdateManager.m index 647592d195..f7e0c12747 100644 --- a/Classes/BITUpdateManager.m +++ b/Classes/BITUpdateManager.m @@ -744,7 +744,7 @@ typedef NS_ENUM(NSInteger, BITUpdateAlertViewTag) { ]; } - NSString *hockeyAPIURL = [NSString stringWithFormat:@"%@api/2/apps/%@?format=plist%@", self.serverURL, [self encodedAppIdentifier], extraParameter]; + NSString *hockeyAPIURL = [NSString stringWithFormat:@"%@api/2/apps/%@/app_versions/%@?format=plist%@", self.serverURL, [self encodedAppIdentifier], [self.newestAppVersion.versionID stringValue], extraParameter]; NSString *iOSUpdateURL = [NSString stringWithFormat:@"itms-services://?action=download-manifest&url=%@", bit_URLEncodedString(hockeyAPIURL)]; BITHockeyLog(@"INFO: API Server Call: %@, calling iOS with %@", hockeyAPIURL, iOSUpdateURL);