Fix shutdown with LUA widgets used

This commit is contained in:
Raphael Coeffic
2021-05-29 13:31:50 +02:00
committed by Raphael Coeffic
parent 836733618c
commit 26bb790d89
+1 -3
View File
@@ -1478,9 +1478,6 @@ void opentxClose(uint8_t shutdown)
// TODO needed? telemetryEnd(); // TODO needed? telemetryEnd();
#if defined(LUA) #if defined(LUA)
luaClose(&lsScripts); luaClose(&lsScripts);
#if defined(COLORLCD)
luaClose(&lsWidgets);
#endif
#endif #endif
#if defined(HAPTIC) #if defined(HAPTIC)
hapticOff(); hapticOff();
@@ -1520,6 +1517,7 @@ void opentxClose(uint8_t shutdown)
//TODO: In fact we want only to empty the trash (private method) //TODO: In fact we want only to empty the trash (private method)
MainWindow::instance()->run(); MainWindow::instance()->run();
luaClose(&lsWidgets);
#endif #endif
#if defined(SDCARD) #if defined(SDCARD)