Fix controller

This commit is contained in:
2026-01-05 23:02:30 +01:00
parent 1797759f93
commit bc21181058

View File

@@ -24,9 +24,9 @@ public class EmailController {
} }
@PostMapping("/mail/send") @PostMapping("/mail/send")
public ResponseEntity<String> send(@RequestBody Map<String, Object> payload){ public ResponseEntity<String> send(@RequestBody String payload){
try { try {
service.send("laurent0206.cr@gmail.com", "Hello from board mate !", payload.get("content").toString()); service.send("laurent0206.cr@gmail.com", "Hello from board mate !", payload);
return new ResponseEntity<>(HttpStatus.OK); return new ResponseEntity<>(HttpStatus.OK);
} catch (Exception e) { } catch (Exception e) {
e.printStackTrace(); e.printStackTrace();