mirror of
https://github.com/moparisthebest/open-keychain
synced 2024-12-24 07:58:50 -05:00
show unknown in ViewKey if user id is not set
This commit is contained in:
parent
c70195e4e3
commit
7b38bfcbf4
@ -301,8 +301,13 @@ public class ViewKeyActivity extends SherlockFragmentActivity implements
|
||||
// get name, email, and comment from USER_ID
|
||||
String[] mainUserId = PgpKeyHelper.splitUserId(data
|
||||
.getString(KEYRING_INDEX_USER_ID));
|
||||
setTitle(mainUserId[0]);
|
||||
mName.setText(mainUserId[0]);
|
||||
if (mainUserId[0] != null && mainUserId[0].length() > 0) {
|
||||
setTitle(mainUserId[0]);
|
||||
mName.setText(mainUserId[0]);
|
||||
} else {
|
||||
setTitle(R.string.unknown_user_id);
|
||||
mName.setText(R.string.unknown_user_id);
|
||||
}
|
||||
mEmail.setText(mainUserId[1]);
|
||||
mComment.setText(mainUserId[2]);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user