diff --git a/src/components/views/rooms/AppsDrawer.js b/src/components/views/rooms/AppsDrawer.js index 1d738fb9d2..a917dde5f6 100644 --- a/src/components/views/rooms/AppsDrawer.js +++ b/src/components/views/rooms/AppsDrawer.js @@ -50,13 +50,12 @@ module.exports = React.createClass({ switch(app.type) { case 'etherpad': - app.url = app.url + '?userName=' + this.props.userId + + app.queryParams = '?userName=' + this.props.userId + '&padId=' + this.props.room.roomId; break; case 'jitsi': { const user = MatrixClientPeg.get().getUser(this.props.userId); - app.url = app.url + - '?confId=' + app.data.confId + + app.queryParams = '?confId=' + app.data.confId + '&displayName=' + encodeURIComponent(user.displayName) + '&avatarUrl=' + encodeURIComponent(MatrixClientPeg.get().mxcUrlToHttp(user.avatarUrl)) + '&email=' + encodeURIComponent(this.props.userId) + @@ -181,15 +180,21 @@ module.exports = React.createClass({ render: function() { const apps = this.state.apps.map( - (app, index, arr) => ); + (app, index, arr) => { + let appUrl = app.url; + if (app.queryParams) { + appUrl += app.queryParams; + } + return ; + }); const addWidget = this.state.apps && this.state.apps.length < 2 && (