Tip payment is a different withdraw reason. (#3937)

* Tip payment is a different withdraw reason.

* Bump runtime version.

* Test fix.

* Fix lock type
This commit is contained in:
Gavin Wood
2019-10-28 13:04:20 +01:00
committed by GitHub
parent e110cd7ae8
commit ec7655cc7b
11 changed files with 49 additions and 40 deletions
+2 -2
View File
@@ -324,7 +324,7 @@ impl<T: Trait> Module<T> {
if let Err(problem) = T::Currency::settle(
&Self::account_id(),
imbalance,
WithdrawReason::Transfer,
WithdrawReason::Transfer.into(),
ExistenceRequirement::KeepAlive
) {
print("Inconsistent state - couldn't settle imbalance for funds spent by treasury");
@@ -657,7 +657,7 @@ mod tests {
<Treasury as OnFinalize<u64>>::on_finalize(4);
assert_eq!(Treasury::pot(), 0); // Pot is emptied
assert_eq!(Balances::free_balance(&Treasury::account_id()), 1); // but the account is still there
assert_eq!(Balances::free_balance(&Treasury::account_id()), 1); // but the account is still there
});
}