diff --git a/api/core/house/house.queries.js b/api/core/house/house.queries.js index d0e24980ad..62fc1b9ae4 100644 --- a/api/core/house/house.queries.js +++ b/api/core/house/house.queries.js @@ -55,6 +55,7 @@ module.exports = { AND house = ? ORDER BY datetime DESC LIMIT 1 ) = 'back-at-home' ) + GROUP BY user.id HAVING datetime < DATE_SUB(NOW(), INTERVAL ? MINUTE) ` }; \ No newline at end of file