Skip to content

Commit 78870cd

Browse files
authored
Revert User::get_webfinger_identifier (#398)
we already have `User::get_resource` to do the same
1 parent d6ff82b commit 78870cd

File tree

1 file changed

+5
-9
lines changed

1 file changed

+5
-9
lines changed

includes/model/class-user.php

Lines changed: 5 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -107,15 +107,6 @@ public function get_at_url() {
107107
return \esc_url( \trailingslashit( get_home_url() ) . '@' . $this->get_username() );
108108
}
109109

110-
/**
111-
* Returns a user@domain type of identifier for the user.
112-
*
113-
* @return string The Webfinger-Identifier.
114-
*/
115-
public function get_webfinger_identifier() {
116-
return sprintf( '%s@%s', $this->get_preferred_username(), wp_parse_url( home_url(), PHP_URL_HOST ) );
117-
}
118-
119110
public function get_preferred_username() {
120111
return \esc_attr( \get_the_author_meta( 'login', $this->_id ) );
121112
}
@@ -298,6 +289,11 @@ public function get_attachment() {
298289
return $array;
299290
}
300291

292+
/**
293+
* Returns a user@domain type of identifier for the user.
294+
*
295+
* @return string The Webfinger-Identifier.
296+
*/
301297
public function get_resource() {
302298
return $this->get_preferred_username() . '@' . \wp_parse_url( \home_url(), \PHP_URL_HOST );
303299
}

0 commit comments

Comments
 (0)