Skip to content

Commit

Permalink
fix: Prevent omni-search to (sometimes) return wrong results (#1445)
Browse files Browse the repository at this point in the history
Co-authored-by: Begoña Álvarez de la Cruz <[email protected]>
  • Loading branch information
msarcev and begonaalvarezd authored Apr 24, 2024
1 parent 73453fa commit 16e32a3
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions api/src/utils/stardust/searchExecutor.ts
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ export class SearchExecutor {
this.apiService
.milestoneDetailsById(searchQuery.milestoneId)
.then((milestoneDetails) => {
if (milestoneDetails) {
if (milestoneDetails.blockId) {
promisesResult = {
milestone: milestoneDetails,
};
Expand Down Expand Up @@ -139,7 +139,7 @@ export class SearchExecutor {
this.apiService
.aliasDetails(searchQuery.aliasId)
.then((aliasOutputs) => {
if (aliasOutputs) {
if (aliasOutputs.aliasDetails) {
promisesResult = {
aliasId: searchQuery.aliasId,
did: searchQuery.did,
Expand All @@ -162,7 +162,7 @@ export class SearchExecutor {
this.apiService
.nftDetails(searchQuery.nftId)
.then((nftOutputs) => {
if (nftOutputs) {
if (nftOutputs.nftDetails) {
promisesResult = {
nftId: searchQuery.nftId,
};
Expand Down

0 comments on commit 16e32a3

Please sign in to comment.