forked from shadowfacts/Tusker
Fix @Published property being changed on background thread
This commit is contained in:
parent
937afc0dfd
commit
37563b6afd
|
@ -321,7 +321,9 @@ class MastodonController: ObservableObject {
|
|||
let request = Client.getCustomEmoji()
|
||||
run(request) { (response) in
|
||||
if case let .success(emojis, _) = response {
|
||||
DispatchQueue.main.async {
|
||||
self.customEmojis = emojis
|
||||
}
|
||||
completion(emojis)
|
||||
} else {
|
||||
completion([])
|
||||
|
|
Loading…
Reference in New Issue