diff --git a/Monal/Classes/ContactsView.swift b/Monal/Classes/ContactsView.swift index df1cec96a..99a14cb27 100644 --- a/Monal/Classes/ContactsView.swift +++ b/Monal/Classes/ContactsView.swift @@ -98,6 +98,12 @@ struct ContactsView: View { @State private var searchText: String = "" @State private var selectedContactForContactDetails: ObservableKVOWrapper? = nil + init(contacts: Contacts, delegate: SheetDismisserProtocol, dismissWithContact: @escaping (MLContact) -> ()) { + self.contacts = contacts + self.delegate = delegate + self.dismissWithContact = dismissWithContact + } + private static func shouldDisplayContact(contact: MLContact) -> Bool { #if IS_QUICKSY return true @@ -128,12 +134,6 @@ struct ContactsView: View { return jid.contains(search) || name.contains(search) } - init(contacts: Contacts, delegate: SheetDismisserProtocol, dismissWithContact: @escaping (MLContact) -> ()) { - self.contacts = contacts - self.delegate = delegate - self.dismissWithContact = dismissWithContact - } - var body: some View { List { ForEach(searchResults, id: \.self) { contact in