Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Summary
Originally, the mcodeApp function in src/application/app.js only changed the logger level if debug was true, and didn't change it back to 'info' if debug was false. Since the UI can run extraction multiple times in a row, this caused a bug.
New behavior
The mcodeApp function now changes the logger level back to 'info' if the debug flag is false.
Code changes
The if statement on line 42 of src/application/app.js was changed to a ternary operator.
Testing guidance
In the root package.json file of code-extraction-ui, set the location of mcode-extraction-framework to "file:local_file_path_to_framework". Run npm install, then npm start. Click on "Extract New", check "Log output debugging information", and then click "Submit". Either look at the terminal to see the logs or, if on the logger-display branch, click on "Log File" in the sidebar of the result page. Click the "Exit" button on the result page, then run extraction again with "Log debugging information" unchecked. Regardless of the order in which you run extraction with and without debug-level logs, as well as the number of times you repeat this process, the proper logs should show up.