Fix client deserialization
This commit is contained in:
@@ -1,6 +1,7 @@
|
||||
package be.naaturel.boardmateapi.controllers;
|
||||
|
||||
import be.naaturel.boardmateapi.common.exceptions.ServiceException;
|
||||
import be.naaturel.boardmateapi.controllers.dtos.ResponseBody;
|
||||
import be.naaturel.boardmateapi.services.MqttService;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.http.HttpStatus;
|
||||
|
||||
@@ -2,10 +2,10 @@ package be.naaturel.boardmateapi.controllers;
|
||||
|
||||
import be.naaturel.boardmateapi.common.exceptions.ServiceException;
|
||||
import be.naaturel.boardmateapi.common.models.Game;
|
||||
import be.naaturel.boardmateapi.controllers.dtos.ResponseBody;
|
||||
import be.naaturel.boardmateapi.controllers.dtos.GameDto;
|
||||
import be.naaturel.boardmateapi.controllers.mappings.GameMapper;
|
||||
import be.naaturel.boardmateapi.services.GameService;
|
||||
import jakarta.websocket.server.PathParam;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.http.HttpStatus;
|
||||
import org.springframework.http.ResponseEntity;
|
||||
@@ -21,17 +21,6 @@ public class GameController {
|
||||
this.service = service;
|
||||
}
|
||||
|
||||
@GetMapping("/games/")
|
||||
public ResponseEntity<?> retrieveAllGames(){
|
||||
try{
|
||||
return ResponseEntity
|
||||
.status(HttpStatus.INTERNAL_SERVER_ERROR)
|
||||
.build();
|
||||
} catch (Exception e){
|
||||
return ResponseEntity.status(HttpStatus.INTERNAL_SERVER_ERROR).build();
|
||||
}
|
||||
}
|
||||
|
||||
@GetMapping("/games/{id}")
|
||||
public ResponseEntity<ResponseBody<GameDto>> retrieveGames(@PathVariable String id){
|
||||
ResponseBody<GameDto> result = ResponseBody.createEmpty();
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
package be.naaturel.boardmateapi.controllers;
|
||||
package be.naaturel.boardmateapi.controllers.dtos;
|
||||
|
||||
import java.util.Optional;
|
||||
|
||||
Reference in New Issue
Block a user