Skip to content
This repository was archived by the owner on Nov 15, 2023. It is now read-only.
Merged
Changes from 1 commit
Commits
Show all changes
24 commits
Select commit Hold shift + click to select a range
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Use frame_support debug
  • Loading branch information
shawntabrizi committed Feb 21, 2020
commit 1181bc2c73076b229e1be4d67e4f230ff1d0211a
12 changes: 9 additions & 3 deletions frame/system/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -113,7 +113,7 @@ use sp_runtime::{

use sp_core::{ChangesTrieConfiguration, storage::well_known_keys};
use frame_support::{
decl_module, decl_event, decl_storage, decl_error, storage, Parameter, ensure,
decl_module, decl_event, decl_storage, decl_error, storage, Parameter, ensure, debug,
traits::{
Contains, Get, ModuleToIndex, OnNewAccount, OnReapAccount, IsDeadAccount, Happened,
StoredMap
Expand Down Expand Up @@ -990,7 +990,10 @@ impl<T: Trait> Happened<T::AccountId> for CallKillAccount<T> {
if Account::<T>::contains_key(who) {
let account = Account::<T>::take(who);
if account.refcount > 0 {
sp_runtime::print("WARNING: Referenced account deleted. This is probably a bug.");
debug::debug!(
target: "system",
"WARNING: Referenced account deleted. This is probably a bug."
);
}
Module::<T>::on_killed_account(who.clone());
}
Expand Down Expand Up @@ -1018,7 +1021,10 @@ impl<T: Trait> StoredMap<T::AccountId, T::AccountData> for Module<T> {
if Account::<T>::contains_key(k) {
let account = Account::<T>::take(k);
if account.refcount > 0 {
sp_runtime::print("WARNING: Referenced account deleted. This is probably a bug.");
debug::debug!(
target: "system",
"WARNING: Referenced account deleted. This is probably a bug."
);
}
Self::on_killed_account(k.clone());
}
Expand Down