summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorYorhel <git@yorhel.nl>2015-11-26 03:00:28 +0100
committerYorhel <git@yorhel.nl>2015-11-26 03:00:28 +0100
commitb2094f4bdcb508701063914f69e1bff29375a477 (patch)
tree982515fdd2c3a13e483960b297f7a37dfe05afb6
parent6a4311639390e3e7321e3e0725ef33575ad45ec0 (diff)
Handler::Discussions: Fix display of username when editing post
-rw-r--r--lib/VNDB/Handler/Discussions.pm2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/VNDB/Handler/Discussions.pm b/lib/VNDB/Handler/Discussions.pm
index ae86010d..79de9c40 100644
--- a/lib/VNDB/Handler/Discussions.pm
+++ b/lib/VNDB/Handler/Discussions.pm
@@ -300,7 +300,7 @@ sub edit {
'_postedit_edit';
$self->htmlHeader(title => $title, noindex => 1);
$self->htmlForm({ frm => $frm, action => $url }, 'postedit' => [$title,
- [ static => label => mt('_postedit_form_username'), content => $self->{l10n}->userstr($self->authInfo->{id}, $self->authInfo->{username}) ],
+ [ static => label => mt('_postedit_form_username'), content => $self->{l10n}->userstr($p ? ($p->{uid}, $p->{username}) : ($self->authInfo->{id}, $self->authInfo->{username})) ],
!$tid || $num == 1 ? (
[ input => short => 'title', name => mt('_postedit_form_title') ],
[ input => short => 'boards', name => mt('_postedit_form_boards') ],