From 27e5ea3cc529765ac4dfccb78acd5f611340c88c Mon Sep 17 00:00:00 2001 From: Miodec Date: Thu, 10 Feb 2022 17:52:07 +0100 Subject: [PATCH] refactor --- frontend/src/js/test/test-logic.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/frontend/src/js/test/test-logic.js b/frontend/src/js/test/test-logic.js index 5fcc86708..857597730 100644 --- a/frontend/src/js/test/test-logic.js +++ b/frontend/src/js/test/test-logic.js @@ -27,7 +27,6 @@ import * as AccountButton from "../elements/account-button"; import * as DB from "../db"; import * as Replay from "./replay.js"; import axiosInstance from "../axios-instance"; -import * as MonkeyPower from "../elements/monkey-power"; import * as Poetry from "./poetry.js"; import * as Wikipedia from "./wikipedia.js"; import * as TodayTracker from "./today-tracker"; @@ -38,6 +37,7 @@ import * as QuoteRatePopup from "../popups/quote-rate-popup"; import * as BritishEnglish from "./british-english"; import * as LazyMode from "./lazy-mode"; import * as Result from "./result"; +import * as MonkeyPower from "./../elements/monkey-power"; const objecthash = require("node-object-hash")().hash; @@ -233,7 +233,6 @@ export let bailout = false; export function setActive(tf) { active = tf; - if (!tf) MonkeyPower.reset(); } export function setRepeated(tf) { @@ -841,6 +840,7 @@ async function getNextWord(wordset, language, wordsBound) { export async function init() { setActive(false); + MonkeyPower.reset(); Replay.stopReplayRecording(); words.reset(); TestUI.setCurrentWordElementIndex(0);