From 8f39f8a23ee2d9be7aba78dcaa5dabde8d6d6065 Mon Sep 17 00:00:00 2001 From: Feross Aboukhadijeh Date: Thu, 19 May 2016 18:55:49 -0700 Subject: [PATCH] After creating torrent, remove create torrent page from forward stack --- renderer/index.js | 3 +++ renderer/views/create-torrent-page.js | 1 - 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/renderer/index.js b/renderer/index.js index 67a367c2..d1f2b3ee 100644 --- a/renderer/index.js +++ b/renderer/index.js @@ -807,6 +807,9 @@ function findFilesRecursive (fileOrFolder, cb) { function createTorrent (options) { var torrentKey = state.nextTorrentKey++ ipcRenderer.send('wt-create-torrent', torrentKey, options) + state.location.backToFirst(function () { + state.location.clearForward('create-torrent') + }) } function torrentInfoHash (torrentKey, infoHash) { diff --git a/renderer/views/create-torrent-page.js b/renderer/views/create-torrent-page.js index 7b8663c0..82fe517e 100644 --- a/renderer/views/create-torrent-page.js +++ b/renderer/views/create-torrent-page.js @@ -119,7 +119,6 @@ function CreateTorrentPage (state) { comment: comment } dispatch('createTorrent', options) - dispatch('backToList') } function handleCancel () {