Compare commits
1 Commits
fix-dep
...
redownload
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
fb33d569ca |
@@ -6,7 +6,7 @@ const LinearProgress = require('material-ui/LinearProgress').default
|
|||||||
|
|
||||||
const TorrentSummary = require('../lib/torrent-summary')
|
const TorrentSummary = require('../lib/torrent-summary')
|
||||||
const TorrentPlayer = require('../lib/torrent-player')
|
const TorrentPlayer = require('../lib/torrent-player')
|
||||||
const { dispatcher } = require('../lib/dispatcher')
|
const { dispatcher, dispatch } = require('../lib/dispatcher')
|
||||||
|
|
||||||
module.exports = class TorrentList extends React.Component {
|
module.exports = class TorrentList extends React.Component {
|
||||||
render () {
|
render () {
|
||||||
@@ -394,10 +394,20 @@ function getErrorMessage (torrentSummary) {
|
|||||||
if (err === 'path-missing') {
|
if (err === 'path-missing') {
|
||||||
return (
|
return (
|
||||||
<span>
|
<span>
|
||||||
Path missing.<br />
|
Torrent data missing.<br />
|
||||||
Fix and restart the app, or delete the torrent.
|
Fix or click to
|
||||||
|
<a onClick={(e) => {
|
||||||
|
e.stopPropagation()
|
||||||
|
restartTorrent(torrentSummary)
|
||||||
|
}}>re-download torrent</a>.
|
||||||
</span>
|
</span>
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
return 'Error'
|
return 'Error'
|
||||||
}
|
}
|
||||||
|
|
||||||
|
function restartTorrent (summary) {
|
||||||
|
delete summary.path
|
||||||
|
delete summary.error
|
||||||
|
dispatch('startTorrentingSummary', summary.torrentKey)
|
||||||
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user