Skip to content

Commit

Permalink
fix: retrieve not deleted sub item only
Browse files Browse the repository at this point in the history
  • Loading branch information
phamhieu committed Mar 22, 2022
1 parent 6816b66 commit dd2017b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/lib/subscription_items.ts
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ export const markDeletedSubscriptionItems = async (
) => {
let prepared = sql(`
select id from "${config.SCHEMA}"."subscription_items"
where subscription = :subscriptionId;
where subscription = :subscriptionId and deleted = false;
`)({ subscriptionId })
const { rows } = await query(prepared.text, prepared.values)
const deletedIds = rows.filter(
Expand Down

0 comments on commit dd2017b

Please sign in to comment.