mirror of
https://github.com/MewoLab/AquaDX.git
synced 2026-02-10 12:47:27 +08:00
[F] Fix account card linking
This commit is contained in:
@@ -96,7 +96,10 @@ class CardController(
|
|||||||
val card = cardService.tryLookup(cardId) ?: (404 - "Card not found")
|
val card = cardService.tryLookup(cardId) ?: (404 - "Card not found")
|
||||||
|
|
||||||
// If the card is not bound to the user
|
// If the card is not bound to the user
|
||||||
if (card.aquaUser != u) 400 - "Card not bound to user"
|
if (card.aquaUser != u) 400 - "Card not linked to user"
|
||||||
|
|
||||||
|
// Ghost cards cannot be unlinked
|
||||||
|
if (card.isGhost) 400 - "Account virtual cards cannot be unlinked"
|
||||||
|
|
||||||
// Unbind the card
|
// Unbind the card
|
||||||
card.aquaUser = null
|
card.aquaUser = null
|
||||||
|
|||||||
Reference in New Issue
Block a user