From 0b040e92e8009c91874f80982c05e97ec34ba16e Mon Sep 17 00:00:00 2001 From: Hajime Hoshi Date: Mon, 4 Apr 2016 02:53:07 +0900 Subject: [PATCH] audio: Bug fix: compilation error on JavaScript --- exp/audio/audio_js.go | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/exp/audio/audio_js.go b/exp/audio/audio_js.go index eb20389c2..9ed606e92 100644 --- a/exp/audio/audio_js.go +++ b/exp/audio/audio_js.go @@ -47,12 +47,12 @@ func startPlaying(src io.Reader, sampleRate int) error { return errors.New("audio: audio couldn't be initialized") } p := &player{ - src: src, - sampleRate: sampleRate, - bufferSource: nil, - context: class.New(), - positionInSamples: int64(p.context.Get("currentTime").Float() * float64(p.sampleRate)), + src: src, + sampleRate: sampleRate, + bufferSource: nil, + context: class.New(), } + p.positionInSamples = int64(p.context.Get("currentTime").Float() * float64(p.sampleRate)) go func() { defer p.close() for {