1
0
mirror of https://github.com/phpbb/phpbb.git synced 2025-04-14 12:52:08 +02:00

Merge pull request #5645 from rxu/ticket/16124

[ticket/16124] Fix users search by last visit time in memberlist.php
This commit is contained in:
Marc Alexander 2019-08-11 20:37:42 +02:00
commit b8f76a9330
No known key found for this signature in database
GPG Key ID: 50E0D2423696F995

View File

@ -1073,7 +1073,18 @@ switch ($mode)
if ($active_time !== false)
{
$sql_where .= " AND u.user_lastvisit " . $find_key_match[$active_select] . ' ' . $active_time;
if ($active_select === 'lt' && (int) $active[0] == 0 && (int) $active[1] == 0 && (int) $active[2] == 0)
{
$sql_where .= ' AND u.user_lastvisit = 0';
}
else if ($active_select === 'gt')
{
$sql_where .= ' AND u.user_lastvisit ' . $find_key_match[$active_select] . ' ' . $active_time;
}
else
{
$sql_where .= ' AND (u.user_lastvisit > 0 AND u.user_lastvisit < ' . $active_time . ')';
}
}
}