feat(wallet): enforce club membership validation for wallet charge operations
Build and Deploy to Kubernetes / build-and-deploy (push) Failing after 19m57s
Build and Deploy to Kubernetes / build-and-deploy (push) Failing after 19m57s
- Added club membership inclusion in user retrieval for ChargeCreditWallet and VerifyCreditWalletCharge command handlers. - Implemented validation to ensure users have an active club membership before allowing wallet charges, throwing a BadRequestException if not. - Updated UserWalletService to handle BadRequestException and return appropriate error messages in responses.
This commit is contained in:
@@ -277,6 +277,14 @@ public class UserWalletService : UserWalletContract.UserWalletContractBase
|
||||
ErrorMessage = ex.Message
|
||||
};
|
||||
}
|
||||
catch (BadRequestException ex)
|
||||
{
|
||||
return new InitiateCreditChargeResponse
|
||||
{
|
||||
IsSuccess = false,
|
||||
ErrorMessage = ex.Message
|
||||
};
|
||||
}
|
||||
}
|
||||
|
||||
// ============= Wallet Verify Methods =============
|
||||
|
||||
Reference in New Issue
Block a user