diff --git a/platypush/backend/http/webapp/src/components/Media/Utils.vue b/platypush/backend/http/webapp/src/components/Media/Utils.vue index 05ec8f38e9..b8310e9aed 100644 --- a/platypush/backend/http/webapp/src/components/Media/Utils.vue +++ b/platypush/backend/http/webapp/src/components/Media/Utils.vue @@ -54,7 +54,7 @@ export default { return ret.join(':') }, - async startStreaming(resource, download=false) { + async startStreaming(resource, pluginName, download=false) { let url = resource let subtitles = null @@ -65,7 +65,7 @@ export default { resource = {url: url} } - const ret = await this.request(`media.start_streaming`, { + const ret = await this.request(`${pluginName}.start_streaming`, { media: url, subtitles: subtitles, download: download, @@ -74,8 +74,8 @@ export default { return {...resource, ...ret} }, - async stopStreaming(mediaId) { - await this.request('media.stop_streaming', {media_id: mediaId}) + async stopStreaming(mediaId, pluginName) { + await this.request(`${pluginName}.stop_streaming`, {media_id: mediaId}) }, }, } diff --git a/platypush/backend/http/webapp/src/components/panels/Media/Index.vue b/platypush/backend/http/webapp/src/components/panels/Media/Index.vue index ea3933ff09..0432eace86 100644 --- a/platypush/backend/http/webapp/src/components/panels/Media/Index.vue +++ b/platypush/backend/http/webapp/src/components/panels/Media/Index.vue @@ -160,7 +160,7 @@ export default { } if (!this.selectedPlayer.component.supports(item)) - item = await this.startStreaming(item) + item = await this.startStreaming(item, this.pluginName) await this.selectedPlayer.component.play(item, this.selectedSubtitles, this.selectedPlayer) await this.refresh() @@ -187,7 +187,7 @@ export default { }, async view(item) { - const ret = await this.startStreaming(item, true) + const ret = await this.startStreaming(item, this.pluginName, true) window.open(ret.url, '_blank') },