Skip to content

Commit 43b54f4

Browse files
Vitalik7zmxv
authored andcommitted
Update example code in README.md (#531)
1 parent a0eb1da commit 43b54f4

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

README.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -84,9 +84,8 @@ var whoosh = new Sound('whoosh.mp3', Sound.MAIN_BUNDLE, (error) => {
8484
}
8585
// loaded successfully
8686
console.log('duration in seconds: ' + whoosh.getDuration() + 'number of channels: ' + whoosh.getNumberOfChannels());
87-
});
88-
89-
// Play the sound with an onEnd callback
87+
88+
// Play the sound with an onEnd callback
9089
whoosh.play((success) => {
9190
if (success) {
9291
console.log('successfully finished playing');
@@ -97,6 +96,7 @@ whoosh.play((success) => {
9796
whoosh.reset();
9897
}
9998
});
99+
});
100100

101101
// Reduce the volume by half
102102
whoosh.setVolume(0.5);

0 commit comments

Comments
 (0)