mirror of
https://github.com/Novaloop-AG/element-x-ios.git
synced 2026-11-04 10:33:45 +00:00
Bump the RustSDK to v1.0.67 (#3512)
* Bump the RustSDK to v1.0.67 * PR comments --------- Co-authored-by: Doug <douglase@element.io>
This commit is contained in:
@@ -135,6 +135,8 @@ class EventTimelineItemProxy {
|
||||
|
||||
lazy var shieldState = item.lazyProvider.getShields(strict: false)
|
||||
|
||||
lazy var sendHandle = item.lazyProvider.getSendHandle()
|
||||
|
||||
lazy var readReceipts = item.readReceipts
|
||||
}
|
||||
|
||||
@@ -179,6 +181,40 @@ struct TimelineItemDebugInfo: Identifiable, CustomStringConvertible {
|
||||
}
|
||||
}
|
||||
|
||||
struct SendHandleProxy: Hashable {
|
||||
enum Error: Swift.Error {
|
||||
case sdkError(Swift.Error)
|
||||
}
|
||||
|
||||
let itemID: TimelineItemIdentifier
|
||||
let underlyingHandle: SendHandle
|
||||
|
||||
func resend() async -> Result<Void, Error> {
|
||||
do {
|
||||
try await underlyingHandle.tryResend()
|
||||
return .success(())
|
||||
} catch {
|
||||
return .failure(.sdkError(error))
|
||||
}
|
||||
}
|
||||
|
||||
// MARK: - Hashable
|
||||
|
||||
static func == (lhs: SendHandleProxy, rhs: SendHandleProxy) -> Bool {
|
||||
lhs.itemID == rhs.itemID
|
||||
}
|
||||
|
||||
func hash(into hasher: inout Hasher) {
|
||||
hasher.combine(itemID)
|
||||
}
|
||||
|
||||
static var mock: SendHandleProxy {
|
||||
.init(itemID: .event(uniqueID: .init(id: UUID().uuidString),
|
||||
eventOrTransactionID: .eventId(eventId: UUID().uuidString)),
|
||||
underlyingHandle: .init(noPointer: .init()))
|
||||
}
|
||||
}
|
||||
|
||||
extension Receipt {
|
||||
var dateTimestamp: Date? {
|
||||
guard let timestamp else {
|
||||
|
||||
Reference in New Issue
Block a user