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) {
|
function moveItemToTrash (torrentSummary) {
|
||||||
// TODO: delete directories, not just files
|
var filePath = path.join(torrentSummary.path, torrentSummary.files[0].path.split('/')[0])
|
||||||
torrentSummary.files.forEach(function (file) {
|
|
||||||
var filePath = path.join(torrentSummary.path, file.path)
|
|
||||||
console.log('DEBUG DELETING ' + filePath)
|
|
||||||
ipcRenderer.send('moveItemToTrash', filePath)
|
ipcRenderer.send('moveItemToTrash', filePath)
|
||||||
})
|
|
||||||
}
|
}
|
||||||
|
|
||||||
function showItemInFolder (torrentSummary) {
|
function showItemInFolder (torrentSummary) {
|
||||||
|
|||||||
Reference in New Issue
Block a user