diff --git a/core/embed/rust/src/ui/model_tr/layout.rs b/core/embed/rust/src/ui/model_tr/layout.rs index 6381256ffa..1d4f4e6238 100644 --- a/core/embed/rust/src/ui/model_tr/layout.rs +++ b/core/embed/rust/src/ui/model_tr/layout.rs @@ -157,7 +157,7 @@ where impl ComponentMsgObj for NumberInput { fn msg_try_into_obj(&self, msg: Self::Msg) -> Result { - msg.try_into() + (CONFIRMED.as_obj(), msg.try_into()?).try_into() } } diff --git a/core/src/trezor/ui/layouts/tr/reset.py b/core/src/trezor/ui/layouts/tr/reset.py index 3a6511479c..28397f1179 100644 --- a/core/src/trezor/ui/layouts/tr/reset.py +++ b/core/src/trezor/ui/layouts/tr/reset.py @@ -161,7 +161,15 @@ async def _prompt_number( ButtonRequestType.ResetDevice, ) - return int(result) + if __debug__: + if isinstance(result, str): + # debuglink for TR sends a string representing the number + result = CONFIRMED, int(result) + status, value = result + + assert status is CONFIRMED + assert isinstance(value, int) + return value async def slip39_prompt_threshold(