From dadfd5d2d94c1230adc1a1295ca3d08ab99349d4 Mon Sep 17 00:00:00 2001 From: karczuRF <88723742+karczuRF@users.noreply.github.com> Date: Wed, 18 Dec 2024 11:20:11 +0100 Subject: [PATCH] fix: missing types (#1221) Description --- Fixing errors while compilation because of invalid types. Motivation and Context --- How Has This Been Tested? --- What process can a PR reviewer use to test or verify this change? --- Breaking Changes --- - [x] None - [ ] Requires data directory to be deleted - [ ] Other - Please specify --- dan_layer/engine_types/src/published_template.rs | 6 ++++++ dan_layer/template_lib/src/panic_hook.rs | 2 +- 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/dan_layer/engine_types/src/published_template.rs b/dan_layer/engine_types/src/published_template.rs index 408ef5165..0a9f71de3 100644 --- a/dan_layer/engine_types/src/published_template.rs +++ b/dan_layer/engine_types/src/published_template.rs @@ -63,6 +63,12 @@ impl FromStr for PublishedTemplateAddress { } } +impl borsh::BorshSerialize for PublishedTemplateAddress { + fn serialize(&self, writer: &mut W) -> std::io::Result<()> { + borsh::BorshSerialize::serialize(self.as_object_key().array(), writer) + } +} + #[derive(Debug, Clone, Serialize, Deserialize)] #[cfg_attr( feature = "ts", diff --git a/dan_layer/template_lib/src/panic_hook.rs b/dan_layer/template_lib/src/panic_hook.rs index 3ee3e0dde..6ce16372c 100644 --- a/dan_layer/template_lib/src/panic_hook.rs +++ b/dan_layer/template_lib/src/panic_hook.rs @@ -24,7 +24,7 @@ use tari_template_abi::on_panic; -fn hook(info: &std::panic::PanicHookInfo<'_>) { +fn hook(info: &std::panic::PanicInfo<'_>) { let error_msg = info .payload() .downcast_ref::()