mirror of
https://github.com/fawney19/Aether.git
synced 2026-09-02 17:30:23 +08:00
fix(wallet): 修复额度耗尽后仍可消费
This commit is contained in:
@@ -63,10 +63,7 @@ impl WalletSnapshot {
|
||||
}
|
||||
}
|
||||
|
||||
pub fn access_decision(&self, is_admin: bool) -> WalletAccessDecision {
|
||||
if is_admin {
|
||||
return WalletAccessDecision::allowed(None);
|
||||
}
|
||||
pub fn access_decision(&self, _is_admin: bool) -> WalletAccessDecision {
|
||||
if self.status != WalletStatus::Active {
|
||||
return WalletAccessDecision::wallet_unavailable(self.balance_snapshot());
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user