From 85ed39b9d87214a069af6c6ab2b642b6ff8b3386 Mon Sep 17 00:00:00 2001 From: David Baker Date: Mon, 8 May 2017 16:49:40 +0100 Subject: [PATCH] Put room name in 'leave room' confirmation dialog https://github.com/vector-im/riot-web/issues/3850 --- src/components/structures/MatrixChat.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/components/structures/MatrixChat.js b/src/components/structures/MatrixChat.js index 9b8aa3426a4..8865d77d519 100644 --- a/src/components/structures/MatrixChat.js +++ b/src/components/structures/MatrixChat.js @@ -392,9 +392,10 @@ module.exports = React.createClass({ this.notifyNewScreen('forgot_password'); break; case 'leave_room': + const roomToLeave = MatrixClientPeg.get().getRoom(payload.room_id); Modal.createDialog(QuestionDialog, { title: "Leave room", - description: "Are you sure you want to leave the room?", + description: Are you sure you want to leave the room {roomToLeave.name}?, onFinished: (should_leave) => { if (should_leave) { const d = MatrixClientPeg.get().leave(payload.room_id);