Skip to content

Commit

Permalink
fix: warn correctly on missing prev locations
Browse files Browse the repository at this point in the history
  • Loading branch information
rafaelcr committed Jul 25, 2023
1 parent b8f6f96 commit 879bf55
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions src/pg/pg-store.ts
Original file line number Diff line number Diff line change
Expand Up @@ -665,8 +665,7 @@ export class PgStore extends BasePgStore {
if (args.location.prev_output) {
const prev = await sql`
SELECT id FROM locations
WHERE genesis_id = ${args.location.genesis_id}
AND prev_output = ${args.location.prev_output}
WHERE genesis_id = ${args.location.genesis_id} AND output = ${args.location.prev_output}
`;
if (prev.count === 0) {
logger.warn(
Expand Down

0 comments on commit 879bf55

Please sign in to comment.