Skip to content

Commit 69076ac

Browse files
authored
Merge pull request #75 from Staketab/dev
fix nullpointer exception
2 parents e499feb + e5d12b3 commit 69076ac

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

src/main/java/com/staketab/minanames/controller/DomainController.java

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -66,8 +66,9 @@ public Page<DomainEntity> getAccountDomains(@Valid @ParameterObject BaseRequest
6666
@Parameter(description = "Domain status") DomainStatus domainStatus,
6767
@RequestParam(required = false, defaultValue = "")
6868
@Parameter(description = "Domain Name") String searchStr) {
69+
String status = domainStatus != null ? domainStatus.name() : null;
6970
SearchParams searchParams = new SearchParams(searchStr);
70-
return domainService.findAllByAccountPageable(request.withSortColumn(sortBy), accountAddress, searchParams, domainStatus.name());
71+
return domainService.findAllByAccountPageable(request.withSortColumn(sortBy), accountAddress, searchParams, status);
7172
}
7273

7374
@GetMapping("/simple")

0 commit comments

Comments
 (0)