moved outputToFile variable to main.js to preserve status even when the extension sidebar is closed.