mirror of
https://github.com/zhw2590582/ArtPlayer.git
synced 2026-10-08 19:06:15 -08:00
Update durationMix.js
This commit is contained in:
1 parent
463ce7bf39
commit
5cdf65d32f
1 file changed
+5
-1
@@ -2,6 +2,10 @@ import { def } from '../utils';
|
||||
|
||||
export default function durationMix(art, player) {
|
||||
def(player, 'duration', {
|
||||
get: () => art.template.$video.duration || 0,
|
||||
get: () => {
|
||||
const { duration } = art.template.$video;
|
||||
if (duration === Infinity) return 0;
|
||||
return duration || 0;
|
||||
},
|
||||
});
|
||||
}
|
||||
Reference in new issue
Block a user