mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-06-14 15:41:02 +00:00
Replace bitmask with bitflags (#7159)
Signed-off-by: koushiro <koushiro.cqx@gmail.com>
This commit is contained in:
@@ -162,7 +162,7 @@ use frame_support::{
|
||||
decl_module, decl_storage, decl_event, decl_error, ensure, Parameter,
|
||||
weights::{Weight, DispatchClass, Pays},
|
||||
traits::{
|
||||
Currency, ReservableCurrency, LockableCurrency, WithdrawReason, LockIdentifier, Get,
|
||||
Currency, ReservableCurrency, LockableCurrency, WithdrawReasons, LockIdentifier, Get,
|
||||
OnUnbalanced, BalanceStatus, schedule::{Named as ScheduleNamed, DispatchTime}, EnsureOrigin
|
||||
},
|
||||
dispatch::DispatchResultWithPostInfo,
|
||||
@@ -1278,7 +1278,7 @@ impl<T: Trait> Module<T> {
|
||||
DEMOCRACY_ID,
|
||||
who,
|
||||
vote.balance(),
|
||||
WithdrawReason::Transfer.into()
|
||||
WithdrawReasons::TRANSFER
|
||||
);
|
||||
ReferendumInfoOf::<T>::insert(ref_index, ReferendumInfo::Ongoing(status));
|
||||
Ok(())
|
||||
@@ -1410,7 +1410,7 @@ impl<T: Trait> Module<T> {
|
||||
DEMOCRACY_ID,
|
||||
&who,
|
||||
balance,
|
||||
WithdrawReason::Transfer.into()
|
||||
WithdrawReasons::TRANSFER
|
||||
);
|
||||
Ok(votes)
|
||||
})?;
|
||||
@@ -1461,7 +1461,7 @@ impl<T: Trait> Module<T> {
|
||||
if lock_needed.is_zero() {
|
||||
T::Currency::remove_lock(DEMOCRACY_ID, who);
|
||||
} else {
|
||||
T::Currency::set_lock(DEMOCRACY_ID, who, lock_needed, WithdrawReason::Transfer.into());
|
||||
T::Currency::set_lock(DEMOCRACY_ID, who, lock_needed, WithdrawReasons::TRANSFER);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user