- if ($author["author-link"] == "") {
- $author["author-link"] = $author["author-id"];
- }
- if ($author["author-link"] == "") {
- $self = $xpath->query("atom:link[@rel='self']")->item(0)->attributes;
+ if (empty($author["author-link"])) {
+ $self = XML::getFirstAttributes($xpath, "atom:link[@rel='self']");