!65 稳定性问题处理

Merge pull request !65 from zhouhongli2023/master
This commit is contained in:
openharmony_ci 2023-10-11 11:21:18 +00:00 committed by Gitee
commit 0bcbc738af
No known key found for this signature in database
GPG Key ID: 173E9B9CA92EEF8F

View File

@ -291,7 +291,10 @@ export default class ReceiveController {
if (this.selectContacts.length == 0) {
return '';
}
let myName = this.selectContacts[0]?.contactName.trim();
let myName = this.selectContacts[0]?.contactName?.trim();
if (!myName) {
myName = ""
}
let telephone = this.selectContacts[0]?.telephone
if (telephone === undefined || telephone === null) {
Hilog.e(TAG, "setShowContactName fail");