ソースを参照

fixed logs clearing

Gildas 7 年 前
コミット
93b2840bf8
1 ファイル変更2 行追加2 行削除
  1. 2 2
      extension/ui/content/content-ui.js

+ 2 - 2
extension/ui/content/content-ui.js

@@ -30,7 +30,7 @@ this.singlefile.ui = this.singlefile.ui || (() => {
 
 
 	let selectedAreaElement;
 	let selectedAreaElement;
 
 
-	const logsWindowElement = createLogsWindowElement();
+	let logsWindowElement = createLogsWindowElement();
 
 
 	return {
 	return {
 		getSelectedArea,
 		getSelectedArea,
@@ -111,7 +111,7 @@ this.singlefile.ui = this.singlefile.ui || (() => {
 	}
 	}
 
 
 	function clearLogs() {
 	function clearLogs() {
-		logsWindowElement.childNodes.forEach(node => node.remove());
+		logsWindowElement = createLogsWindowElement();
 	}
 	}
 
 
 	function getSelectedArea() {
 	function getSelectedArea() {