# status.
if ($message =~ /^statu?s$/i) {
- my $startString = scalar(localtime $^T);
+ my $startString = scalar(gmtime $^T);
my $upString = &Time2String(time() - $^T);
- my $count = &countKeys("factoids");
+ my $factoids = &countKeys("factoids");
$count{'Commands'} = 0;
foreach (keys %cmdstats) {
" and \002$count{'Commands'}\002 ".
&fixPlural("command",$count{'Commands'}).
". I have been awake for $upString this session, and ".
- "currently reference \002$count\002 factoids. ".
+ "currently reference \002$factoids\002 factoids. ".
"I'm using about \002$memusage\002 ".
"kB of memory."
);
+ return;
+
# todo: use dbGetColNiceHash().
- my %hash = &dbGetCol("stats", "nick,counter", "type='cmdstats'".
-# " ORDER BY counter DESC LIMIT 3", 1);
- " ORDER BY counter DESC", 1);
+ my %hash = &sqlSelectColHash("stats", "nick,counter",
+ { type => "cmdstats" }, 1);
+# does ORDER matter when used with a hash?
+# " ORDER BY counter DESC", 1);
if (0) {
foreach (keys %hash) {