mirror of
https://github.com/WiiLink24/wfc-server.git
synced 2026-09-10 01:25:57 -05:00
API: Allow more advanced group filtering
This commit is contained in:
@@ -24,8 +24,7 @@ func HandleGroups(w http.ResponseWriter, r *http.Request) {
|
||||
return
|
||||
}
|
||||
|
||||
gameName := query.Get("game")
|
||||
groups := qr2.GetGroups(gameName)
|
||||
groups := qr2.GetGroups(query["game"], query["id"])
|
||||
|
||||
for _, group := range groups {
|
||||
for i, player := range group.Players {
|
||||
|
||||
@@ -35,7 +35,7 @@ func HandleStats(w http.ResponseWriter, r *http.Request) {
|
||||
stats := map[string]Stats{}
|
||||
|
||||
servers := qr2.GetSessionServers()
|
||||
groups := qr2.GetGroups("")
|
||||
groups := qr2.GetGroups([]string{}, []string{})
|
||||
|
||||
globalStats := Stats{
|
||||
OnlinePlayerCount: len(servers),
|
||||
|
||||
Reference in New Issue
Block a user