mirror of
https://github.com/NuSkooler/enigma-bbs.git
synced 2025-08-05 09:21:30 +02:00
Change column name, drop a useless one
This commit is contained in:
parent
90137819dd
commit
403ee891d5
3 changed files with 7 additions and 8 deletions
|
@ -180,7 +180,7 @@ class Achievements {
|
|||
UserDb.get(
|
||||
`SELECT COUNT() AS count
|
||||
FROM user_achievement
|
||||
WHERE user_id = ? AND achievement_tag = ? AND match_field = ?;`,
|
||||
WHERE user_id = ? AND achievement_tag = ? AND match = ?;`,
|
||||
[ user.userId, achievementTag, field],
|
||||
(err, row) => {
|
||||
return cb(err, row ? row.count : 0);
|
||||
|
@ -193,9 +193,9 @@ class Achievements {
|
|||
StatLog.incrementUserStat(info.client.user, UserProps.AchievementTotalPoints, info.details.points);
|
||||
|
||||
UserDb.run(
|
||||
`INSERT INTO user_achievement (user_id, achievement_tag, timestamp, match_field, match_value)
|
||||
VALUES (?, ?, ?, ?, ?);`,
|
||||
[ info.client.user.userId, info.achievementTag, getISOTimestampString(info.timestamp), info.matchField, info.matchValue ],
|
||||
`INSERT INTO user_achievement (user_id, achievement_tag, timestamp, match)
|
||||
VALUES (?, ?, ?, ?);`,
|
||||
[ info.client.user.userId, info.achievementTag, getISOTimestampString(info.timestamp), info.matchField ],
|
||||
err => {
|
||||
if(err) {
|
||||
return cb(err);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue