Files
damus/damus/Models/ProfileUpdate.swift
William Casarin fc9b9f2940 ndb: switch profile queries to use transactions
this should ensure no crashing occurs when querying profiles
2023-09-21 09:10:06 -04:00

24 lines
402 B
Swift

//
// ProfileUpdate.swift
// damus
//
// Created by William Casarin on 2022-05-06.
//
import Foundation
enum ProfileUpdate {
case manual(pubkey: Pubkey, profile: Profile)
case remote(pubkey: Pubkey)
var pubkey: Pubkey {
switch self {
case .manual(let pubkey, _):
return pubkey
case .remote(let pubkey):
return pubkey
}
}
}