Search long and short names

This commit is contained in:
Garth Vander Houwen 2023-08-21 23:51:51 -07:00
parent 51813cbd86
commit f4e6393baa

View file

@ -19,7 +19,7 @@ struct NodeList: View {
searchText
} set: { newValue in
searchText = newValue
nodes.nsPredicate = newValue.isEmpty ? nil : NSPredicate(format: "user.longName CONTAINS[c] %@", newValue)
nodes.nsPredicate = newValue.isEmpty ? nil : NSPredicate(format: "user.longName CONTAINS[c] %@ OR user.shortName CONTAINS[c] %@", newValue, newValue)
}
}