Ignore meta.deleted for account name display
This commit is contained in:
parent
f7586109df
commit
5bdb6e4f22
@ -27,18 +27,17 @@ export function personalAccountsInfo (accountsInfo) {
|
|||||||
|
|
||||||
Object.keys(accountsInfo || {})
|
Object.keys(accountsInfo || {})
|
||||||
.map((address) => Object.assign({}, accountsInfo[address], { address }))
|
.map((address) => Object.assign({}, accountsInfo[address], { address }))
|
||||||
|
.filter((account) => account.uuid || !account.meta.deleted)
|
||||||
.forEach((account) => {
|
.forEach((account) => {
|
||||||
if (account.uuid) {
|
if (account.uuid) {
|
||||||
accounts[account.address] = account;
|
accounts[account.address] = account;
|
||||||
} else if (!account.meta.deleted) {
|
} else if (account.meta.wallet) {
|
||||||
if (account.meta.wallet) {
|
account.wallet = true;
|
||||||
account.wallet = true;
|
wallets[account.address] = account;
|
||||||
wallets[account.address] = account;
|
} else if (account.meta.contract) {
|
||||||
} else if (account.meta.contract) {
|
contracts[account.address] = account;
|
||||||
contracts[account.address] = account;
|
} else {
|
||||||
} else {
|
contacts[account.address] = account;
|
||||||
contacts[account.address] = account;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
|
@ -37,7 +37,7 @@ class IdentityName extends Component {
|
|||||||
render () {
|
render () {
|
||||||
const { address, accountsInfo, tokens, empty, name, shorten, unknown, className } = this.props;
|
const { address, accountsInfo, tokens, empty, name, shorten, unknown, className } = this.props;
|
||||||
const account = accountsInfo[address] || tokens[address];
|
const account = accountsInfo[address] || tokens[address];
|
||||||
const hasAccount = account && (!account.meta || !account.meta.deleted);
|
const hasAccount = account && (account.uuid || !account.meta || !account.meta.deleted);
|
||||||
|
|
||||||
if (!hasAccount && empty) {
|
if (!hasAccount && empty) {
|
||||||
return null;
|
return null;
|
||||||
|
Loading…
Reference in New Issue
Block a user