Skip to content

Commit

Permalink
handle empty results from a google search
Browse files Browse the repository at this point in the history
  • Loading branch information
horrible-little-slime committed Jun 3, 2024
1 parent f3c5bdc commit 93cfcc7
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion packages/oaf/src/clients/wiki.ts
Original file line number Diff line number Diff line change
Expand Up @@ -538,7 +538,7 @@ export class WikiClient {
}

// No results found
if (results.items.length === 0) return null;
if (!results.items?.length) return null;
return parseFoundName(results.items[0].link);
}

Expand Down

0 comments on commit 93cfcc7

Please sign in to comment.