1
0
mirror of https://github.com/trezor/trezor-firmware.git synced 2024-11-27 01:48:17 +00:00

fix(core): fix enabling/disabling haptics before the driver is initialized

[no changelog]
This commit is contained in:
tychovrahe 2024-11-22 16:25:26 +01:00 committed by TychoVrahe
parent a0a0c93d0d
commit 904327cea5

View File

@ -217,6 +217,10 @@ void haptic_deinit(void) {
void haptic_set_enabled(bool enabled) {
haptic_driver_t *driver = &g_haptic_driver;
if (!driver->initialized) {
return;
}
driver->enabled = enabled;
}