1
0
mirror of https://github.com/trezor/trezor-firmware.git synced 2025-07-13 01:58:08 +00:00

core: only softlock when PIN is set

This commit is contained in:
matejcik 2020-04-24 12:16:32 +02:00 committed by matejcik
parent a9ddc2a8e2
commit b9bd9ea3d0

View File

@ -130,9 +130,10 @@ def set_homescreen() -> None:
def lock_device() -> None: def lock_device() -> None:
config.lock() if config.has_pin():
set_homescreen() config.lock()
wire.find_handler = get_pinlocked_handler set_homescreen()
wire.find_handler = get_pinlocked_handler
async def unlock_device(ctx: wire.GenericContext = wire.DUMMY_CONTEXT) -> None: async def unlock_device(ctx: wire.GenericContext = wire.DUMMY_CONTEXT) -> None: