From 320db51b726910bea9803bbb879ee41a14d48dee Mon Sep 17 00:00:00 2001 From: devland Date: Thu, 7 Nov 2024 08:54:56 +0100 Subject: [PATCH] JI-6731 move code block within correct scope --- scripts/h5peditor-av.js | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/scripts/h5peditor-av.js b/scripts/h5peditor-av.js index 315774c2..b275baa2 100644 --- a/scripts/h5peditor-av.js +++ b/scripts/h5peditor-av.js @@ -881,13 +881,12 @@ H5PEditor.widgets.video = H5PEditor.widgets.audio = H5PEditor.AV = (function ($) }; this.params.push(file); this.setValue(this.field, this.params); + for (i = 0; i < this.changes.length; i++) { + this.changes[i](file); + } } index = this.params.findIndex(param => param.path === url); this.addFile(index); - - for (i = 0; i < this.changes.length; i++) { - this.changes[i](file); - } }; /**