What is the problem?
When you close the WhoWroteThat tool for the second time, all the content is removed from the article.
To speculate wildly, I think it is possibly related to the use of the replaceWith() function in App.js:onWidgetClose(). replaceWith() removes the object from the DOM. When replaceWith() is called a second time on the same object (which has previously been removed), it does not have the same affect.
This bug was found by @Mooeypoo.
Steps to reproduce problem
Install the extension using the instructions.
- Go to any article
- In the sidebar, click "Who Wrote That?"
- Once the tool has loaded, on the infobar at the top click the close icon
- Click "Who Wrote That?" again
- Click the close icon again
Expected behavior: Tool is closed. Article returns to normal.
Observed behavior: Article content is removed.