fixed bug with the navigation error constraint and all and clean now
This commit is contained in:
@@ -62,8 +62,6 @@ class ContactsViewModel : ObservableObject {
|
|||||||
if formattedNumber != nil && formattedNumber!.count > 9 { // don't want the grant cardone texts to show up
|
if formattedNumber != nil && formattedNumber!.count > 9 { // don't want the grant cardone texts to show up
|
||||||
formattedNumber = "+1" + formattedNumber! // adding country code
|
formattedNumber = "+1" + formattedNumber! // adding country code
|
||||||
|
|
||||||
print(formattedNumber)
|
|
||||||
|
|
||||||
let contactNumber = String(formattedNumber!)
|
let contactNumber = String(formattedNumber!)
|
||||||
var contactVm = ContactsViewModelContact(cnName: contactDisplayName, cnPhoneNumber: contactNumber, sortingProp: contactDisplayName)
|
var contactVm = ContactsViewModelContact(cnName: contactDisplayName, cnPhoneNumber: contactNumber, sortingProp: contactDisplayName)
|
||||||
|
|
||||||
@@ -120,3 +118,4 @@ struct ContactsViewModelContact : Identifiable {
|
|||||||
var isExisting: Bool = false
|
var isExisting: Bool = false
|
||||||
var sortingProp: String
|
var sortingProp: String
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -35,6 +35,7 @@ struct FindFriendsView: View {
|
|||||||
}
|
}
|
||||||
.searchable(text: self.$searchQuery)
|
.searchable(text: self.$searchQuery)
|
||||||
}
|
}
|
||||||
|
.navigationBarTitle("Find Friends")
|
||||||
.navigationBarItems(
|
.navigationBarItems(
|
||||||
leading:
|
leading:
|
||||||
Button {
|
Button {
|
||||||
@@ -46,8 +47,8 @@ struct FindFriendsView: View {
|
|||||||
.foregroundColor(NirvanaColor.teal)
|
.foregroundColor(NirvanaColor.teal)
|
||||||
}
|
}
|
||||||
)
|
)
|
||||||
.navigationBarTitle("Find Friends")
|
|
||||||
}
|
}
|
||||||
|
.navigationViewStyle(StackNavigationViewStyle())
|
||||||
.onAppear {
|
.onAppear {
|
||||||
self.contactsVM.fetchContacts()
|
self.contactsVM.fetchContacts()
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user