Skip to content

Commit

Permalink
Fix instance deletion
Browse files Browse the repository at this point in the history
  • Loading branch information
philogicae committed Sep 6, 2024
1 parent cf7f5be commit 12079a1
Showing 1 changed file with 11 additions and 2 deletions.
13 changes: 11 additions & 2 deletions src/domain/instance.ts
Original file line number Diff line number Diff line change
Expand Up @@ -225,7 +225,10 @@ export class InstanceManager
},
})

await account.decreaseALEPHFlow(receiver, instanceCosts.totalCost)
await account.decreaseALEPHFlow(
receiver,
instanceCosts.totalCost + EXTRA_WEI,
)
}

try {
Expand Down Expand Up @@ -423,7 +426,13 @@ export class InstanceManager
instancesOrIds = Array.isArray(instancesOrIds)
? instancesOrIds
: [instancesOrIds]
instancesOrIds.forEach(() => {
instancesOrIds.forEach((instance) => {
if (
typeof instance !== 'string' &&
instance.payment?.type === PaymentType.superfluid &&
instance.payment?.receiver
)
steps.push('streamDel')
steps.push('instanceDel')
})
return steps
Expand Down

0 comments on commit 12079a1

Please sign in to comment.