Skip to content

Commit

Permalink
fix(server/storage): missing operator (#76)
Browse files Browse the repository at this point in the history
  • Loading branch information
mafewtm authored Sep 22, 2024
1 parent 98a44a5 commit e0b4832
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion server/storage.lua
Original file line number Diff line number Diff line change
Expand Up @@ -22,5 +22,5 @@ end
---@return table?
function GetPlayerActivityData(citizenid, job)
local result = MySQL.single.await('SELECT `last_checkin`, ROUND(COALESCE(SUM(last_checkout-last_checkin) / 3600, 0), 2) AS `hours` FROM `player_jobs_activity` WHERE `citizenid` = ? AND `job` = ? GROUP BY `citizenid`', { citizenid, job })
return { hours = result?.hours or 0, last_checkin = result?.last_checkin and os.date(config.formatDateTime, result.last_checkin) or 'N/A' }
return { hours = result?.hours or 0, last_checkin = result?.last_checkin and os.date(config.formatDateTime, result?.last_checkin) or 'N/A' }
end

0 comments on commit e0b4832

Please sign in to comment.