From aaf516c62d6b36aa2d21fd016a2552e9edc866ee Mon Sep 17 00:00:00 2001 From: Mauricio Fierro Date: Fri, 15 Mar 2024 23:04:43 -0500 Subject: [PATCH] Fix setting duration for new lesson Duration is a target, not a value. --- app/javascript/controllers/player_controller.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/javascript/controllers/player_controller.js b/app/javascript/controllers/player_controller.js index d386354..da9f852 100644 --- a/app/javascript/controllers/player_controller.js +++ b/app/javascript/controllers/player_controller.js @@ -204,7 +204,7 @@ export default class extends Controller { onPause: () => {}, onPlaying: () => { // TODO: This is a float so check the backend - if(this.hasDurationValue) { + if(this.hasDurationTarget) { this.durationTarget.value = parseInt(this.player.duration) } }}