Skip to content

Commit

Permalink
Don't do passport scan updates on withdrawal
Browse files Browse the repository at this point in the history
  • Loading branch information
violog committed Jun 20, 2024
1 parent e820b6e commit 5e9a4c4
Showing 1 changed file with 0 additions and 9 deletions.
9 changes: 0 additions & 9 deletions internal/service/handlers/withdraw.go
Original file line number Diff line number Diff line change
Expand Up @@ -79,15 +79,6 @@ func Withdraw(w http.ResponseWriter, r *http.Request) {

var withdrawal *data.Withdrawal
err = EventsQ(r).Transaction(func() error {
// If user hasn't provided passport proof yet, do all the necessary updates to
// potentially reduce the number of proofs in UX
if balance.Country == nil {
if err = doPassportScanUpdates(r, *balance, countryCode, true); err != nil {
return fmt.Errorf("do passport scan updates: %w", err)
}
log.Debug("Successfully performed passport scan updates already")
}

err = BalancesQ(r).FilterByNullifier(nullifier).Update(map[string]any{
data.ColAmount: pg.AddToValue(data.ColAmount, -req.Data.Attributes.Amount),
})
Expand Down

0 comments on commit 5e9a4c4

Please sign in to comment.