mirror of
https://github.com/VueTorrent/VueTorrent.git
synced 2025-04-01 14:24:12 +03:00
fix: size error when deleting torrents under certain conditions (#870)
This commit is contained in:
parent
87038f48b9
commit
09828cb9ab
1 changed files with 3 additions and 2 deletions
|
@ -23,8 +23,9 @@ export default {
|
||||||
getTorrentCountString: (state: StoreState, getters: any) => () => {
|
getTorrentCountString: (state: StoreState, getters: any) => () => {
|
||||||
if (state.selected_torrents.length) {
|
if (state.selected_torrents.length) {
|
||||||
let selectedSize = state.selected_torrents
|
let selectedSize = state.selected_torrents
|
||||||
.map(hash => getters.getTorrent(hash))
|
.map(getters.getTorrent)
|
||||||
.map(torrent => torrent.size | 0)
|
.filter(torrent => torrent !== undefined)
|
||||||
|
.map(torrent => torrent.size)
|
||||||
.reduce((partialSum, newVal) => partialSum + newVal)
|
.reduce((partialSum, newVal) => partialSum + newVal)
|
||||||
|
|
||||||
return i18n
|
return i18n
|
||||||
|
|
Loading…
Add table
Reference in a new issue