File tree Expand file tree Collapse file tree 1 file changed +2
-2
lines changed
code/spring-boot-telemetry/src/main/java/com/azure/examples/springboot/controller Expand file tree Collapse file tree 1 file changed +2
-2
lines changed Original file line number Diff line number Diff line change @@ -48,7 +48,7 @@ public ResponseEntity<VeggieItem> addVeggie(@RequestBody VeggieItem veggie) {
4848 }
4949
5050 @ DeleteMapping ("/{id}" )
51- public ResponseEntity <String > deleteVeggie (@ PathVariable ("id" ) Long id ) {
51+ public ResponseEntity <String > deleteVeggie (@ PathVariable ("id" ) String id ) {
5252 veggieService .deleteVeggie (id );
5353 return ResponseEntity .ok ("Veggie deleted successfully" );
5454 }
@@ -60,7 +60,7 @@ public ResponseEntity<List<VeggieItem>> getAllVeggies() {
6060 }
6161
6262 @ GetMapping ("/{id}" )
63- public ResponseEntity <VeggieItem > getVeggieById (@ PathVariable ("id" ) Long id ) {
63+ public ResponseEntity <VeggieItem > getVeggieById (@ PathVariable ("id" ) String id ) {
6464 VeggieItem veggie = veggieService .getVeggieById (id );
6565 if (veggie != null ) {
6666 return ResponseEntity .ok (veggie );
You can’t perform that action at this time.
0 commit comments