[chusan]Attempting to ensure compatibility with all known versions of Chusan, both before and after SunPlus

This commit is contained in:
HoshimiRIN
2023-12-17 21:50:09 +08:00
parent c8e1c5fbb7
commit 7a7076b174
11 changed files with 223 additions and 29 deletions

View File

@@ -12,7 +12,7 @@ import java.util.Map;
* @author samnyan (privateamusement@protonmail.com)
*/
@RestController
@RequestMapping({"/ChusanServlet/ChuniServlet", "/ChusanServlet"})
@RequestMapping({"/ChusanServlet/{version}/ChuniServlet", "/ChusanServlet/{version}"})
public class ChusanServletController {
private final GameLoginHandler gameLoginHandler;
@@ -235,7 +235,8 @@ public class ChusanServletController {
}
@PostMapping("GetUserMusicApi")
String getUserMusic(@ModelAttribute Map<String, Object> request) throws JsonProcessingException {
String getUserMusic(@ModelAttribute Map<String, Object> request, @PathVariable String version) throws JsonProcessingException {
request.put("version", version);
return getUserMusicHandler.handle(request);
}