summaryrefslogtreecommitdiff
path: root/feed.php
diff options
context:
space:
mode:
authorGina Haeussge <gina@foosel.net>2010-06-26 13:28:21 +0200
committerGina Haeussge <gina@foosel.net>2010-06-26 13:28:21 +0200
commit681a59b23795166231cfebc0da4d0d219d528795 (patch)
tree8a41a938574a2f26cbcafb04cd651c2aaf22d3d4 /feed.php
parent69266de50f71b3d43011378cf0b0e8b8185c3609 (diff)
downloadrpg-681a59b23795166231cfebc0da4d0d219d528795.tar.gz
rpg-681a59b23795166231cfebc0da4d0d219d528795.tar.bz2
FS#1884: respect $conf['showuseras'] in feeds
Diffstat (limited to 'feed.php')
-rw-r--r--feed.php13
1 files changed, 12 insertions, 1 deletions
diff --git a/feed.php b/feed.php
index 73227e055..50786dd3a 100644
--- a/feed.php
+++ b/feed.php
@@ -253,7 +253,18 @@ function rss_buildItems(&$rss,&$data,$opt){
$item->author = '';
if($user && $conf['useacl'] && $auth){
$userInfo = $auth->getUserData($user);
- $item->author = $userInfo['name'];
+ if ($userInfo){
+ switch ($conf['showuseras']){
+ case 'username':
+ $item->author = $userInfo['name'];
+ break;
+ default:
+ $item->author = $user;
+ break;
+ }
+ } else {
+ $item->author = $user;
+ }
if($userInfo && !$opt['guardmail']){
$item->authorEmail = $userInfo['mail'];
}else{