3
0
mirror of https://github.com/pragma-/pbot.git synced 2024-11-30 07:59:42 +01:00

Update last_seen hostmask field in WHO replies

This commit is contained in:
Pragmatic Software 2016-11-29 01:43:11 -08:00
parent 5012886d71
commit 3537b74877

View File

@ -261,6 +261,7 @@ sub on_whospcrpl {
$self->{pbot}->{logger}->log("WHO id: $id, hostmask: $hostmask, $nickserv, $gecos.\n"); $self->{pbot}->{logger}->log("WHO id: $id, hostmask: $hostmask, $nickserv, $gecos.\n");
my $account_id = $self->{pbot}->{messagehistory}->{database}->get_message_account($nick, $user, $host); my $account_id = $self->{pbot}->{messagehistory}->{database}->get_message_account($nick, $user, $host);
$self->{pbot}->{messagehistory}->{database}->update_hostmask_data($hostmask, { last_seen => scalar gettimeofday });
if ($nickserv ne '0') { if ($nickserv ne '0') {
$self->{pbot}->{messagehistory}->{database}->link_aliases($account_id, undef, $nickserv); $self->{pbot}->{messagehistory}->{database}->link_aliases($account_id, undef, $nickserv);