Minor fix for issue when plugin is running in the background