File tree Expand file tree Collapse file tree 1 file changed +13
-3
lines changed
Flow.Launcher.Core/Plugin Expand file tree Collapse file tree 1 file changed +13
-3
lines changed Original file line number Diff line number Diff line change @@ -220,9 +220,19 @@ public static async Task InitializePluginsAsync()
220220 catch ( Exception e )
221221 {
222222 API . LogException ( ClassName , $ "Fail to Init plugin: { pair . Metadata . Name } ", e ) ;
223- pair . Metadata . Disabled = true ;
224- pair . Metadata . HomeDisabled = true ;
225- failedPlugins . Enqueue ( pair ) ;
223+ if ( pair . Metadata . Disabled && pair . Metadata . HomeDisabled )
224+ {
225+ // If this plugin is already disabled, do not show error message again
226+ // Or else it will be shown every time
227+ API . LogDebug ( ClassName , $ "Skipped init for <{ pair . Metadata . Name } > due to error") ;
228+ }
229+ else
230+ {
231+ pair . Metadata . Disabled = true ;
232+ pair . Metadata . HomeDisabled = true ;
233+ failedPlugins . Enqueue ( pair ) ;
234+ API . LogDebug ( ClassName , $ "Disable plugin <{ pair . Metadata . Name } > because init failed") ;
235+ }
226236 }
227237 } ) ) ;
228238
You can’t perform that action at this time.
0 commit comments