mirror of
https://github.com/pragma-/pbot.git
synced 2024-12-22 18:52:40 +01:00
Core/Factoids: top20
: show only defined edited-by
for edited
sub-command
This commit is contained in:
parent
4345b0a75c
commit
f542cc0cf2
@ -1430,6 +1430,7 @@ sub cmd_top20($self, $context) {
|
||||
if (lc $args eq 'edited') {
|
||||
my $iter = $factoids->get_each('type = text', "index1 = $channel", 'index2', 'edited_on', 'edited_by', '_sort = -edited_on');
|
||||
while (defined (my $factoid = $factoids->get_next($iter))) {
|
||||
last if not defined $factoid->{'edited_on'};
|
||||
my $ago = concise ago gettimeofday - $factoid->{'edited_on'};
|
||||
my ($editor) = $factoid->{'edited_by'} =~ /^([^!]+)/;
|
||||
$text .= ' ' . $factoids->get_data($factoid->{index1}, $factoid->{index2}, '_name') . " [$ago by $editor]\n";
|
||||
|
@ -25,7 +25,7 @@ use PBot::Imports;
|
||||
# These are set by the /misc/update_version script
|
||||
use constant {
|
||||
BUILD_NAME => "PBot",
|
||||
BUILD_REVISION => 4810,
|
||||
BUILD_REVISION => 4811,
|
||||
BUILD_DATE => "2024-10-23",
|
||||
};
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user