remove torrent data (single file / folder)
This commit is contained in:
@@ -243,14 +243,10 @@ function deleteFile (path) {
|
||||
})
|
||||
}
|
||||
|
||||
// Delete all files in a torren
|
||||
// Delete all files in a torrent
|
||||
function moveItemToTrash (torrentSummary) {
|
||||
// TODO: delete directories, not just files
|
||||
torrentSummary.files.forEach(function (file) {
|
||||
var filePath = path.join(torrentSummary.path, file.path)
|
||||
console.log('DEBUG DELETING ' + filePath)
|
||||
ipcRenderer.send('moveItemToTrash', filePath)
|
||||
})
|
||||
var filePath = path.join(torrentSummary.path, torrentSummary.files[0].path.split('/')[0])
|
||||
ipcRenderer.send('moveItemToTrash', filePath)
|
||||
}
|
||||
|
||||
function showItemInFolder (torrentSummary) {
|
||||
|
||||
Reference in New Issue
Block a user