Skip to content

Commit

Permalink
Merge pull request #4 from emdgroup/fix/2_clone-schema
Browse files Browse the repository at this point in the history
fix: clone schema and indexes #2
  • Loading branch information
monken authored Apr 24, 2023
2 parents 7e1906f + ee15cde commit 663cd85
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -213,7 +213,7 @@ export class PaginationResponse<T extends AttributeMap = AttributeMap> {
}

private clone<K extends AttributeMap>(args: Partial<PaginationResponseOptions<K>>): PaginationResponse<K | T> {
const { _limit: limit, _from: from, _query: query, _filter: filter, client, key, method } = this;
const { _limit: limit, _from: from, _query: query, _filter: filter, client, key, method, schema, indexes } = this;
return new PaginationResponse<K | T>({
client,
key,
Expand All @@ -222,6 +222,8 @@ export class PaginationResponse<T extends AttributeMap = AttributeMap> {
from,
limit,
method,
schema,
indexes,
...args,
});
}
Expand Down

0 comments on commit 663cd85

Please sign in to comment.