Merge branch 'hotfix/2.11.4' into mkirk/fix-push-sync-job

pull/1/head
Michael Kirk 8 years ago
commit 929ba06263

@ -38,7 +38,7 @@
<key>CFBundlePackageType</key>
<string>APPL</string>
<key>CFBundleShortVersionString</key>
<string>2.11.3</string>
<string>2.11.4</string>
<key>CFBundleSignature</key>
<string>????</string>
<key>CFBundleURLTypes</key>
@ -55,7 +55,7 @@
</dict>
</array>
<key>CFBundleVersion</key>
<string>2.11.3.0</string>
<string>2.11.4.1</string>
<key>ITSAppUsesNonExemptEncryption</key>
<false/>
<key>LOGS_EMAIL</key>

@ -93,6 +93,8 @@ static NSString *const kURLHostVerifyPrefix = @"verify";
DDLogWarn(@"%@ application: didFinishLaunchingWithOptions.", self.tag);
[AppVersion instance];
// Set the seed the generator for rand().
//
// We should always use arc4random() instead of rand(), but we

@ -37,6 +37,17 @@ class SyncPushTokensJob: NSObject {
Logger.debug("\(self.TAG) push tokens changed.")
}
Logger.warn("\(self.TAG) lastAppVersion: \(AppVersion.instance().lastAppVersion), currentAppVersion: \(AppVersion.instance().currentAppVersion)")
if AppVersion.instance().lastAppVersion != AppVersion.instance().currentAppVersion {
Logger.debug("\(self.TAG) Fresh install or app upgrade.")
shouldUploadTokens = true
}
guard shouldUploadTokens else {
Logger.warn("\(self.TAG) Skipping push token upload. pushToken: \(pushToken), voipToken: \(voipToken)")
return Promise(value: ())
}
Logger.warn("\(self.TAG) Sending new tokens to account servers. pushToken: \(pushToken), voipToken: \(voipToken)")
return self.accountManager.updatePushTokens(pushToken:pushToken, voipToken:voipToken).then {

@ -35,6 +35,7 @@
#import <JSQMessagesViewController/UIColor+JSQMessages.h>
#import <JSQSystemSoundPlayer.h>
#import <PureLayout/PureLayout.h>
#import <SignalServiceKit/AppVersion.h>
#import <SignalServiceKit/Contact.h>
#import <SignalServiceKit/ContactsUpdater.h>
#import <SignalServiceKit/Cryptography.h>

@ -18,6 +18,7 @@
#import "TSStorageManager.h"
#import "UIUtil.h"
#import "VersionMigrations.h"
#import <PromiseKit/AnyPromise.h>
#import <SignalServiceKit/OWSBlockingManager.h>
#import <SignalServiceKit/OWSDisappearingMessagesJob.h>
#import <SignalServiceKit/OWSMessageSender.h>

Loading…
Cancel
Save