Fix extra space
This commit is contained in:
@@ -6,7 +6,7 @@ import { Pipe, PipeTransform } from '@angular/core';
|
||||
export class FullNamePipe implements PipeTransform {
|
||||
transform(person: any, args?: any): any {
|
||||
if (person) {
|
||||
return [person.firstName, person.middleName, person.lastName].join(" ");
|
||||
return [person.firstName, person.middleName, person.lastName].filter(Boolean).join(" ");
|
||||
} else {
|
||||
return "";
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user