Drop ifTruthy suffix
This commit is contained in:
parent
b4bf9733ad
commit
1918a88722
1 changed files with 4 additions and 4 deletions
|
@ -73,7 +73,7 @@ export class ContactDetail extends React.Component<Props, {}> {
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
public renderAddressLineIfTruthy(value: string | undefined) {
|
public renderAddressLine(value: string | undefined) {
|
||||||
if (!value) {
|
if (!value) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
@ -117,11 +117,11 @@ export class ContactDetail extends React.Component<Props, {}> {
|
||||||
return (
|
return (
|
||||||
<div key={index} className="additional-contact">
|
<div key={index} className="additional-contact">
|
||||||
<div className="type">{getLabelForAddress(address, i18n)}</div>
|
<div className="type">{getLabelForAddress(address, i18n)}</div>
|
||||||
{this.renderAddressLineIfTruthy(address.street)}
|
{this.renderAddressLine(address.street)}
|
||||||
{this.renderPOBox(address.pobox, i18n)}
|
{this.renderPOBox(address.pobox, i18n)}
|
||||||
{this.renderAddressLineIfTruthy(address.neighborhood)}
|
{this.renderAddressLine(address.neighborhood)}
|
||||||
{this.renderAddressLineTwo(address)}
|
{this.renderAddressLineTwo(address)}
|
||||||
{this.renderAddressLineIfTruthy(address.country)}
|
{this.renderAddressLine(address.country)}
|
||||||
</div>
|
</div>
|
||||||
);
|
);
|
||||||
});
|
});
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue