Skip to content

Commit

Permalink
fix: change paginator model access (smithy-lang#242)
Browse files Browse the repository at this point in the history
  • Loading branch information
alexforsyth authored Jan 6, 2021
1 parent 6e2af31 commit d9b0001
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ final class PaginationGenerator implements Runnable {
this.methodName = Character.toLowerCase(operationName.charAt(0)) + operationName.substring(1);
this.paginationType = this.nonModularServiceName + "PaginationConfiguration";

PaginatedIndex paginatedIndex = model.getKnowledge(PaginatedIndex.class);
PaginatedIndex paginatedIndex = PaginatedIndex.of(model);
Optional<PaginationInfo> paginationInfo = paginatedIndex.getPaginationInfo(service, operation);
this.paginatedInfo = paginationInfo.orElseThrow(() -> {
return new CodegenException("Expected Paginator to have pagination information.");
Expand Down

0 comments on commit d9b0001

Please sign in to comment.