fix: analytics modify

This commit is contained in:
Chen, Tai-Lin committed 2023-12-10 02:21:02 +08:00
1 parent c243e29002
commit 9200336b49
5 files changed
+20 -16

No files matched your search

+6 -2
View File
@@ -2,11 +2,11 @@
/* eslint-disable func-names */
import { UserProfile } from '@linux-odyssey/models'
export function questCount() {
export function totalQuests() {
return UserProfile.find().count()
}
export function questCompleted() {
export function totalCompleted() {
return UserProfile.find({
$where: function () {
for (const key in this.progress) {
@@ -18,3 +18,7 @@ export function questCompleted() {
},
}).count()
}
export function userProfileList() {
return UserProfile.find()
}