Skip to content

Commit

Permalink
Merge pull request #211 from UniqueNetwork/fix/v1.7.11-check-nested-a…
Browse files Browse the repository at this point in the history
…ddress

Fix query nested Tokens
  • Loading branch information
icehuntmen committed Feb 20, 2023
2 parents 86d1183 + 3d3f720 commit 2589978
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 5 deletions.
4 changes: 2 additions & 2 deletions apps/web-api/src/tokens/token.service.ts
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,7 @@ export class TokenService extends BaseService<Tokens, TokenDTO> {
qb.where(
new Brackets((qb) => {
qb.where('parent_id is null').andWhere(
`"Tokens",children @> '[{"token_id": ${token_id}, "collection_id": ${collection_id}}]'::jsonb`,
`"Tokens".children @> '[{"token_id": ${token_id}, "collection_id": ${collection_id}}]'::jsonb`,
);
}),
);
Expand All @@ -113,7 +113,7 @@ export class TokenService extends BaseService<Tokens, TokenDTO> {
.andWhere('"Tokens".collection_id = :collection_id', {
collection_id,
})
.andWhere(`nested = :nested`, { nested: true });
.andWhere(`"Tokens".nested = :nested`, { nested: true });
}),
);

Expand Down
4 changes: 2 additions & 2 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "polkastats-backend-uniquenetwork",
"version": "1.7.11",
"version": "1.7.12",
"description": "",
"author": "Unique Network Team",
"private": true,
Expand Down

0 comments on commit 2589978

Please sign in to comment.