forked from MinecraftUtilities/Backend
oopsie
This commit is contained in:
parent
b7834ab389
commit
2e326bb7be
@ -12,6 +12,7 @@ import org.springframework.web.bind.annotation.RestController;
|
|||||||
import xyz.mcutils.backend.model.cache.CachedEndpointStatus;
|
import xyz.mcutils.backend.model.cache.CachedEndpointStatus;
|
||||||
import xyz.mcutils.backend.service.MojangService;
|
import xyz.mcutils.backend.service.MojangService;
|
||||||
|
|
||||||
|
import java.util.Map;
|
||||||
import java.util.concurrent.TimeUnit;
|
import java.util.concurrent.TimeUnit;
|
||||||
|
|
||||||
@RestController
|
@RestController
|
||||||
@ -27,6 +28,6 @@ public class MojangController {
|
|||||||
public ResponseEntity<?> getStatus() {
|
public ResponseEntity<?> getStatus() {
|
||||||
return ResponseEntity.ok()
|
return ResponseEntity.ok()
|
||||||
.cacheControl(CacheControl.maxAge(1, TimeUnit.MINUTES).cachePublic())
|
.cacheControl(CacheControl.maxAge(1, TimeUnit.MINUTES).cachePublic())
|
||||||
.body(mojangService.getMojangServerStatus());
|
.body(Map.of("endpoints", mojangService.getMojangServerStatus()));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user