mirror of
https://github.com/WiiLink24/wfc-server.git
synced 2026-09-07 08:05:27 -05:00
Merge pull request #57 from MikeIsAStar/allow-get-top-ten-rankings-requests-for-competitions
RACE: Allow 'GetTopTenRankings' requests for competitions
This commit is contained in:
@@ -90,12 +90,19 @@ func handleNintendoRacingServiceRequest(moduleName string, responseWriter http.R
|
||||
logging.Error(moduleName, "Invalid region id")
|
||||
return
|
||||
}
|
||||
if !courseId.IsValid() {
|
||||
if courseId < common.MarioCircuit {
|
||||
logging.Error(moduleName, "Invalid course id")
|
||||
return
|
||||
}
|
||||
|
||||
logging.Info(moduleName, "Received a request for the Top 10 of", aurora.BrightCyan(courseId.ToString()))
|
||||
var topTenLeaderboard string
|
||||
if courseId <= common.GBAShyGuyBeach {
|
||||
topTenLeaderboard = courseId.ToString()
|
||||
} else {
|
||||
topTenLeaderboard = "a competition"
|
||||
}
|
||||
|
||||
logging.Info(moduleName, "Received a request for the Top 10 of", aurora.BrightCyan(topTenLeaderboard))
|
||||
handleGetTopTenRankingsRequest(moduleName, responseWriter)
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user