diff --git a/src/services/ruffle_service/ruffle_service.js b/src/services/ruffle_service/ruffle_service.js index 61fe1e1953..7411dd962d 100644 --- a/src/services/ruffle_service/ruffle_service.js +++ b/src/services/ruffle_service/ruffle_service.js @@ -2,7 +2,10 @@ const createRuffleService = () => { let ruffleInstance = null const getRuffle = () => new Promise((resolve, reject) => { - if (ruffleInstance) resolve(ruffleInstance) + if (ruffleInstance) { + resolve(ruffleInstance) + return + } // Ruffle needs these to be set before it's loaded // https://github.com/ruffle-rs/ruffle/issues/3952 window.RufflePlayer = {}