CB-1255: Media.stop calls the success callback twice I took the call to the success callback out of Media.stop. Just letting the Media.onStatus method handle calling the success callback when it gets a status of STOPPED.
Project: http://git-wip-us.apache.org/repos/asf/incubator-cordova-js/repo Commit: http://git-wip-us.apache.org/repos/asf/incubator-cordova-js/commit/114232a6 Tree: http://git-wip-us.apache.org/repos/asf/incubator-cordova-js/tree/114232a6 Diff: http://git-wip-us.apache.org/repos/asf/incubator-cordova-js/diff/114232a6 Branch: refs/heads/master Commit: 114232a6323183d9464cbc1eaed7765289914e22 Parents: 33d1ef2 Author: macdonst <simon.macdon...@gmail.com> Authored: Fri Aug 17 11:35:16 2012 -0400 Committer: macdonst <simon.macdon...@gmail.com> Committed: Fri Aug 17 11:35:26 2012 -0400 ---------------------------------------------------------------------- lib/common/plugin/Media.js | 1 - 1 files changed, 0 insertions(+), 1 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/incubator-cordova-js/blob/114232a6/lib/common/plugin/Media.js ---------------------------------------------------------------------- diff --git a/lib/common/plugin/Media.js b/lib/common/plugin/Media.js index 50b3bfe..6b5310d 100644 --- a/lib/common/plugin/Media.js +++ b/lib/common/plugin/Media.js @@ -79,7 +79,6 @@ Media.prototype.stop = function() { var me = this; exec(function() { me._position = 0; - me.successCallback(); }, this.errorCallback, "Media", "stopPlayingAudio", [this.id]); };