Changed getData to use ResponseEntity