Skip to content

Commit

Permalink
Item14548: respect user cloak for registrationdate
Browse files Browse the repository at this point in the history
  • Loading branch information
MichaelDaum committed Oct 13, 2020
1 parent 7aef787 commit 41ca231
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion core/lib/Foswiki/Macros/USERINFO.pm
Expand Up @@ -51,7 +51,12 @@ my %USERINFO_tokens = (
},
registrationdate => sub {
my ( $this, $user ) = @_;
return $this->{users}->getRegistrationDate($user) || "";

return '' if ($USERINFO_cloak);

my $date = $this->{users}->getRegistrationDate($user) || "";
$date = Foswiki::Time::formatTime($date) if $date =~ /^\d+$/;
return $date;
},
emails => sub {
my ( $this, $user ) = @_;
Expand Down

0 comments on commit 41ca231

Please sign in to comment.