bind pub -|- !idle irc:idle
proc irc:idle { nick uhost hand channel text } {
        global sqlcmd
        if { ![info exists text]} { set text $channel }
        foreach thisnick [chanlist $text] {
                if {![info exist x]} { set x "\{$thisnick [getchanidle $thisnick $text]\} "; continue; }
                append x "\{$thisnick [getchanidle $thisnick $text]\} "
                putlog "$thisnick - [real_time [getchanidle $thisnick $text]]"
        }
        putlog $x
        putlog "--"
        lsort -index 1 -increasing $x
        putlog "---"
        putlog $x
}
