Skip to content

Commit

Permalink
签到问题
Browse files Browse the repository at this point in the history
  • Loading branch information
CuteReimu committed Sep 6, 2024
1 parent 09788a8 commit 8be166f
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/main/kotlin/gm/Getlasttime.kt
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,8 @@ class Getlasttime : Function<Map<String, String>, Any> {
return try {
val name = form["name"]!!
val playerInfo = Statistics.getPlayerInfo(name)
if (playerInfo == null || playerInfo.score <= 0) "{\"result\": 0}"
else "{\"result\": \"${System.currentTimeMillis() - playerInfo.lastTime}\"}"
if (playerInfo == null || playerInfo.energy <= 0) "{\"result\": 0}"
else "{\"result\": ${System.currentTimeMillis() - playerInfo.lastTime}}"
} catch (e: NullPointerException) {
"{\"error\": \"参数错误\"}"
}
Expand Down

0 comments on commit 8be166f

Please sign in to comment.