Skip to content

Commit 6063cb1

Browse files
Merge pull request #750 from montoyamoraga/main
add info from deleted wikis and ran npm lint
2 parents 25699ed + 19ff942 commit 6063cb1

File tree

2 files changed

+473
-92
lines changed

2 files changed

+473
-92
lines changed

src/audioWorklet/index.js

Lines changed: 9 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -9,14 +9,17 @@ let initializedAudioWorklets = false;
99

1010
function loadAudioWorkletModules() {
1111
return Promise.all(
12-
moduleSources.map(function(moduleSrc) {
12+
moduleSources.map(function (moduleSrc) {
1313
const blob = new Blob([moduleSrc], { type: 'application/javascript' });
1414
const objectURL = URL.createObjectURL(blob);
15-
return ac.audioWorklet
16-
.addModule(objectURL)
17-
// in "p5 instance mode," the module may already be registered
18-
.catch(() => Promise.resolve());
19-
}));
15+
return (
16+
ac.audioWorklet
17+
.addModule(objectURL)
18+
// in "p5 instance mode," the module may already be registered
19+
.catch(() => Promise.resolve())
20+
);
21+
})
22+
);
2023
}
2124

2225
p5.prototype.registerMethod('init', function () {

0 commit comments

Comments
 (0)