mirror of
https://github.com/LBPUnion/ProjectLighthouse.git
synced 2025-05-14 22:02:26 +00:00
Fix total queued levels count on Vita
This commit is contained in:
parent
7249248e45
commit
40d7562660
1 changed files with 7 additions and 4 deletions
|
@ -53,8 +53,11 @@ public class ListController : ControllerBase
|
||||||
|
|
||||||
return this.Ok
|
return this.Ok
|
||||||
(
|
(
|
||||||
LbpSerializer.TaggedStringElement
|
LbpSerializer.TaggedStringElement("slots", response, new Dictionary<string, object>
|
||||||
("slots", response, "total", this.database.QueuedLevels.Include(q => q.User).Count(q => q.User.Username == username))
|
{
|
||||||
|
{ "total", await this.database.QueuedLevels.CountAsync(q => q.UserId == token.UserId) },
|
||||||
|
{ "hint_start", pageStart + Math.Min(pageSize, 30) },
|
||||||
|
})
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -136,7 +139,7 @@ public class ListController : ControllerBase
|
||||||
(
|
(
|
||||||
LbpSerializer.TaggedStringElement("favouriteSlots", response, new Dictionary<string, object>
|
LbpSerializer.TaggedStringElement("favouriteSlots", response, new Dictionary<string, object>
|
||||||
{
|
{
|
||||||
{ "total", this.database.HeartedLevels.Count(q => q.UserId == targetUser.UserId) },
|
{ "total", await this.database.HeartedLevels.CountAsync(q => q.UserId == targetUser.UserId) },
|
||||||
{ "hint_start", pageStart + Math.Min(pageSize, 30) },
|
{ "hint_start", pageStart + Math.Min(pageSize, 30) },
|
||||||
})
|
})
|
||||||
);
|
);
|
||||||
|
@ -225,7 +228,7 @@ public class ListController : ControllerBase
|
||||||
(
|
(
|
||||||
LbpSerializer.TaggedStringElement("favouriteUsers", response, new Dictionary<string, object>
|
LbpSerializer.TaggedStringElement("favouriteUsers", response, new Dictionary<string, object>
|
||||||
{
|
{
|
||||||
{ "total", this.database.HeartedProfiles.Count(q => q.UserId == targetUser.UserId) },
|
{ "total", await this.database.HeartedProfiles.CountAsync(q => q.UserId == targetUser.UserId) },
|
||||||
{ "hint_start", pageStart + Math.Min(pageSize, 30) },
|
{ "hint_start", pageStart + Math.Min(pageSize, 30) },
|
||||||
})
|
})
|
||||||
);
|
);
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue