Skip to content

Commit

Permalink
Remove old use of 1GB constant (#5096)
Browse files Browse the repository at this point in the history
* Remove old use of 1GB constant

* Fix clippy
  • Loading branch information
neacsu authored Nov 5, 2024
1 parent 15ca24b commit 69e97b3
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions common/wireguard/src/peer_controller.rs
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,8 @@ use defguard_wireguard_rs::{
WireguardInterfaceApi,
};
use futures::channel::oneshot;
use nym_authenticator_requests::{
latest::registration::RemainingBandwidthData, v1::registration::BANDWIDTH_CAP_PER_DAY,
use nym_authenticator_requests::latest::registration::{
RemainingBandwidthData, BANDWIDTH_CAP_PER_DAY,
};
use nym_credential_verification::{
bandwidth_storage_manager::BandwidthStorageManager, BandwidthFlushingBehaviourConfig,
Expand Down Expand Up @@ -230,7 +230,7 @@ impl<St: Storage + Clone + 'static> PeerController<St> {
// host information not updated yet
return Ok(None);
};
BANDWIDTH_CAP_PER_DAY.saturating_sub((peer.rx_bytes + peer.tx_bytes) as i64)
BANDWIDTH_CAP_PER_DAY.saturating_sub(peer.rx_bytes + peer.tx_bytes) as i64
};

Ok(Some(RemainingBandwidthData {
Expand Down

0 comments on commit 69e97b3

Please sign in to comment.