File tree Expand file tree Collapse file tree 1 file changed +7
-1
lines changed
app/src/main/kotlin/com/simplemobiletools/contacts/pro/helpers Expand file tree Collapse file tree 1 file changed +7
-1
lines changed Original file line number Diff line number Diff line change @@ -722,8 +722,14 @@ class ContactsHelper(val context: Context) {
722722 var middleName = " "
723723 var surname = " "
724724 var suffix = " "
725- val mimetype = cursor.getStringValue(Data .MIMETYPE )
725+ var mimetype = cursor.getStringValue(Data .MIMETYPE )
726726
727+ // if first line is an Organization type contact, go to next line
728+ if (mimetype != StructuredName .CONTENT_ITEM_TYPE ) {
729+ if (cursor.moveToNext()) {
730+ mimetype = cursor.getStringValue(Data .MIMETYPE )
731+ }
732+ }
727733 // ignore names at Organization type contacts
728734 if (mimetype == StructuredName .CONTENT_ITEM_TYPE ) {
729735 prefix = cursor.getStringValue(StructuredName .PREFIX ) ? : " "
You can’t perform that action at this time.
0 commit comments