Skip to content

Fix: CAPITALISM tax & transaction error handling bugs#24

Merged
Maxlego08 merged 1 commit into
GroupeZ-dev:developfrom
daniel-skopek:tax-fix
Jun 17, 2026
Merged

Fix: CAPITALISM tax & transaction error handling bugs#24
Maxlego08 merged 1 commit into
GroupeZ-dev:developfrom
daniel-skopek:tax-fix

Conversation

@daniel-skopek

Copy link
Copy Markdown
Contributor

Balance check fixes

  • PurchaseService & ListedItemsButton: CAPITALISM tax now included in
    pre-purchase balance check (was checking base price only, allowing
    buyers who couldn't afford price+tax to pass)
  • PurchaseService: item status now restored from IS_BEING_PURCHASED
    to previous status on insufficient funds, preventing items from
    becoming permanently unclickable in the UI

Transaction error handling (ZAuctionManager)

  • withdraw() wrapped in try-catch; throws on failure to abort
    the purchase via existing CompletableFuture exception handler
  • deposit() to seller wrapped in try-catch with automatic buyer
    refund on failure
  • Seller transaction before field corrected for deferred deposits
    (was balance - amount even when no deposit occurred)

Claim service fixes

  • Removed fire-and-forget runAsync for deposits; now synchronous
    before marking transactions as RETRIEVED, preventing money loss
    on server crash
  • Added try-catch around all deposit calls with error logging

@Maxlego08
Maxlego08 changed the base branch from main to develop June 17, 2026 19:15
@Maxlego08
Maxlego08 merged commit 1443e30 into GroupeZ-dev:develop Jun 17, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants