Skip to content

Commit 61230c6

Browse files
committed
Use err() instead of Module["printErr"]()
1 parent 1c8438e commit 61230c6

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

music_html5.c

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -276,7 +276,7 @@ static int MusicHTML5_Open(const SDL_AudioSpec *spec)
276276
if (!(audio instanceof HTMLMediaElement))
277277
return;
278278

279-
Module["printErr"]("Error " + audio.error.code + "; details: " + audio.error.message);
279+
err("Error " + audio.error.code + "; details: " + audio.error.message);
280280

281281
Module["SDL2Mixer"].resetMusicState(audio);
282282
},
@@ -489,9 +489,9 @@ static int MusicHTML5_Play(void *context, int play_count)
489489

490490
// Older browsers do not return a Promise
491491
if (played)
492-
played.catch((e) => Module["printErr"](e));
492+
played.catch((e) => err(e));
493493
} catch (e) {
494-
Module["printErr"](e);
494+
err(e);
495495
return -1;
496496
}
497497
return 0;

0 commit comments

Comments
 (0)