contracts Add LOG_TARGET constant (#14002)

* contracts Add LOG_TARGET constant

* Update frame/contracts/src/lib.rs

Co-authored-by: Sasha Gryaznov <hi@agryaznov.com>

---------

Co-authored-by: Sasha Gryaznov <hi@agryaznov.com>
This commit is contained in:
PG HerveouandSasha Gryaznov authored and GitHub committed 2023-04-25 11:46:20 +00:00
1 parent bcf7601169
commit c11cb1b274
5 files changed
+21 -14

No files matched your search

@@ -19,7 +19,7 @@
use crate::{
storage::{ContractInfo, DepositAccount},
BalanceOf, Config, Error, Inspect, Pallet, System,
BalanceOf, Config, Error, Inspect, Pallet, System, LOG_TARGET,
};
use codec::Encode;
use frame_support::{
@@ -502,7 +502,7 @@ impl<T: Config> Ext<T> for ReservingExt {
);
if let Err(err) = result {
log::error!(
target: "runtime::contracts",
target: LOG_TARGET,
"Failed to transfer storage deposit {:?} from origin {:?} to deposit account {:?}: {:?}",
amount, origin, deposit_account, err,
);
@@ -531,7 +531,7 @@ impl<T: Config> Ext<T> for ReservingExt {
);
if matches!(result, Err(_)) {
log::error!(
target: "runtime::contracts",
target: LOG_TARGET,
"Failed to refund storage deposit {:?} from deposit account {:?} to origin {:?}: {:?}",
amount, deposit_account, origin, result,
);