Skip to content

Commit

Permalink
Switch addZone response to ResponseEntity<String>
Browse files Browse the repository at this point in the history
  • Loading branch information
th-schwarz committed Jul 27, 2024
1 parent ee2e6c9 commit 3d42409
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/main/java/codes/thischwa/dyndrest/ApiController.java
Original file line number Diff line number Diff line change
Expand Up @@ -125,7 +125,7 @@ public ResponseEntity<IpSetting> info(String host, @RequestParam String apitoken
}

@Override
public ResponseEntity<Object> addZone(String name, String ns) {
public ResponseEntity<String> addZone(String name, String ns) {
log.debug("entered #addZone: name={}, ns={}", name, ns);
if (!domainNameValidator.isValidDomainNames(name, ns)) {
log.error("Domain name ({}) or nameserver ({}) is malformed.", name, ns);
Expand Down
2 changes: 1 addition & 1 deletion src/main/java/codes/thischwa/dyndrest/ApiRoutes.java
Original file line number Diff line number Diff line change
Expand Up @@ -128,7 +128,7 @@ ResponseEntity<IpSetting> info(
String apitoken);

@GetMapping(value = "/zone/add/{name}/{ns}", produces = MediaType.TEXT_PLAIN_VALUE)
ResponseEntity<Object> addZone(
ResponseEntity<String> addZone(
@Parameter(
description = "The name of the zone, must be a valid domain name.",
content = @Content(mediaType = MediaType.TEXT_PLAIN_VALUE),
Expand Down

0 comments on commit 3d42409

Please sign in to comment.