From fefe43d91b5a2e7bf6ee41e6cf3cbd598d481fcc Mon Sep 17 00:00:00 2001 From: Jordan Rose Date: Wed, 6 Jan 2021 14:17:36 -0800 Subject: [PATCH] SSK: Adopt SignalClient.SessionRecord.hasCurrentState --- Podfile.lock | 8 ++++---- Pods | 2 +- .../src/Storage/AxolotlStore/SSKSessionStore.swift | 5 ++--- 3 files changed, 7 insertions(+), 8 deletions(-) diff --git a/Podfile.lock b/Podfile.lock index d377c9d822..80f8171fe2 100644 --- a/Podfile.lock +++ b/Podfile.lock @@ -83,9 +83,9 @@ PODS: - SAMKeychain (1.5.3) - SignalArgon2 (1.3.2) - SignalArgon2/Tests (1.3.2) - - SignalClient (0.1.0): + - SignalClient (0.1.1): - SignalCoreKit - - SignalClient/Tests (0.1.0): + - SignalClient/Tests (0.1.1): - SignalCoreKit - SignalCoreKit (1.0.0): - CocoaLumberjack @@ -371,7 +371,7 @@ CHECKOUT OPTIONS: :git: https://github.com/signalapp/Argon2.git :submodules: true SignalClient: - :commit: d1b8d4a6d4c34f5c0e027d76a765eb5127f97f4d + :commit: 32604e1d35e0ebeb5a8530dc30620b7f7dea3299 :git: https://github.com/signalapp/libsignal-client.git SignalCoreKit: :commit: 21c092e94b307690957b50f2305e5e65d28fa89e @@ -414,7 +414,7 @@ SPEC CHECKSUMS: Reachability: 33e18b67625424e47b6cde6d202dce689ad7af96 SAMKeychain: 483e1c9f32984d50ca961e26818a534283b4cd5c SignalArgon2: 1c24183835ca861e6af06631c18b1671cdf35571 - SignalClient: 6f79dbba1667960c60f091a42ab5cfd4e418ff82 + SignalClient: 48f5b0faf7e50a36e0fc0949cb3f68d8f499986e SignalCoreKit: 4562b2bbd9830077439ca003f952a798457d4ea5 SignalMetadataKit: a40217605426975468175eb9328a170e2162be94 SignalRingRTC: d59de0ae05da586f043f83e5a6f7e5bc0c60a482 diff --git a/Pods b/Pods index e697a1ba60..6bcd5d9dd9 160000 --- a/Pods +++ b/Pods @@ -1 +1 @@ -Subproject commit e697a1ba60f89a48385cf14f628a7f82578302ab +Subproject commit 6bcd5d9dd9acad80453f42cc343dc639310c9529 diff --git a/SignalServiceKit/src/Storage/AxolotlStore/SSKSessionStore.swift b/SignalServiceKit/src/Storage/AxolotlStore/SSKSessionStore.swift index 7aeb91959e..8c84794a60 100644 --- a/SignalServiceKit/src/Storage/AxolotlStore/SSKSessionStore.swift +++ b/SignalServiceKit/src/Storage/AxolotlStore/SSKSessionStore.swift @@ -95,9 +95,8 @@ public class SSKSessionStore: NSObject { } do { - // FIXME: Expose a SignalClient version of this instead of poking at the protobuf. - let sessionStructure = try SessionRecordProtos_RecordStructure(serializedData: serializedData) - return sessionStructure.hasCurrentSession + let session = try SignalClient.SessionRecord(bytes: serializedData) + return session.hasCurrentState } catch { owsFailDebug("serialized session data was not valid: \(error)") return false