Parcourir la source

我解锁音频9

zhangyujun il y a 3 ans
Parent
commit
2dbef47742
1 fichiers modifiés avec 3 ajouts et 0 suppressions
  1. 3 0
      src/hooks/light/audio.ts

+ 3 - 0
src/hooks/light/audio.ts

@@ -29,6 +29,9 @@ export function useAudio() {
             sound.on('playerror',(err)=>{
                 alert(err)
              })
+             sound.on('loaderror',(err)=>{
+                alert(err)
+             })
             sound.once("load", function () {
                 let id = sound.play();
                 if (id) {