| @@ -114,8 +114,18 @@ | ||
| 114 | 114 | } |
| 115 | 115 | if ( empty( $fullname ) && ! empty( $this->meta['display_name'] ) ) { |
| 116 | 116 | $fullname = esc_html( $this->meta['display_name'] ); |
| 117 | 117 | } |
| 118 | + | |
| 119 | + if ( empty( $fullname ) && isset( $this->meta['first_name'] ) && isset( $this->meta['last_name'] ) ) { | |
| 120 | + $first_name = trim( (string) $this->meta['first_name'] ); | |
| 121 | + $last_name = trim( (string) $this->meta['last_name'] ); | |
| 122 | + $full_name = trim( $first_name . ' ' . $last_name ); | |
| 123 | + if ( '' !== $full_name ) { | |
| 124 | + $fullname = esc_html( $full_name ); | |
| 125 | + } | |
| 126 | + } | |
| 127 | + | |
| 118 | 128 | if ( empty( $fullname ) && ! empty( $this->meta['username'] ) ) { |
| 119 | 129 | $fullname = esc_html( $this->meta['username'] ); |
| 120 | 130 | } |
| 121 | 131 | return $fullname; |