Merge pull request #8230 from AlfredSK/AlfredSK-statistics-query

Changed statistics query for nodeinfo
This commit is contained in:
Hypolite Petovan 2020-02-09 17:54:22 -05:00 committed by GitHub
commit 097620b627
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -1123,11 +1123,14 @@ class User
$userStmt = DBA::p("SELECT `user`.`uid`, `user`.`login_date`, `contact`.`last-item` $userStmt = DBA::p("SELECT `user`.`uid`, `user`.`login_date`, `contact`.`last-item`
FROM `user` FROM `user`
INNER JOIN `profile` ON `profile`.`uid` = `user`.`uid`
INNER JOIN `contact` ON `contact`.`uid` = `user`.`uid` AND `contact`.`self` INNER JOIN `contact` ON `contact`.`uid` = `user`.`uid` AND `contact`.`self`
WHERE (`profile`.`publish` OR `profile`.`net-publish`) AND `user`.`verified` WHERE `user`.`verified`
AND NOT `user`.`blocked` AND NOT `user`.`account_removed` AND `user`.`login_date` > ?
AND NOT `user`.`account_expired`"); AND NOT `user`.`blocked`
AND NOT `user`.`account_removed`
AND NOT `user`.`account_expired`",
DBA::NULL_DATETIME
);
if (!DBA::isResult($userStmt)) { if (!DBA::isResult($userStmt)) {
return $statistics; return $statistics;