From 3795af6cb5230fd1b185566eaa354fe4a04c4ec6 Mon Sep 17 00:00:00 2001 From: toasted-nutbread Date: Tue, 25 Feb 2020 19:54:59 -0500 Subject: [PATCH] Use Object.entries rather than for in --- ext/bg/js/deinflector.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ext/bg/js/deinflector.js b/ext/bg/js/deinflector.js index e2ced965..d548d271 100644 --- a/ext/bg/js/deinflector.js +++ b/ext/bg/js/deinflector.js @@ -57,9 +57,9 @@ class Deinflector { static normalizeReasons(reasons) { const normalizedReasons = []; - for (const reason in reasons) { + for (const [reason, reasonInfo] of Object.entries(reasons)) { const variants = []; - for (const {kanaIn, kanaOut, rulesIn, rulesOut} of reasons[reason]) { + for (const {kanaIn, kanaOut, rulesIn, rulesOut} of reasonInfo) { variants.push([ kanaIn, kanaOut,