File tree Expand file tree Collapse file tree 1 file changed +11
-2
lines changed Expand file tree Collapse file tree 1 file changed +11
-2
lines changed Original file line number Diff line number Diff line change @@ -74,6 +74,15 @@ export default {
74
74
document . documentElement . appendChild ( div ) ;
75
75
76
76
const formatter = UfsGlobal . Utils . getNumberFormatter ( "compactShort" ) ;
77
+ function getNow ( ) {
78
+ // return year + month + day + hour + minute + second
79
+ const day = new Date ( ) ;
80
+ return (
81
+ [ day . getFullYear ( ) , day . getMonth ( ) + 1 , day . getDate ( ) ] . join ( "-" ) +
82
+ "_" +
83
+ [ day . getHours ( ) , day . getMinutes ( ) , day . getSeconds ( ) ] . join ( "-" )
84
+ ) ;
85
+ }
77
86
78
87
const app = new Vue ( {
79
88
template : /*html*/ `
@@ -290,7 +299,7 @@ export default {
290
299
if ( ! total ) return ;
291
300
let success = 0 ;
292
301
await download ( {
293
- folderName : "tiktok_videos" ,
302
+ folderName : "tiktok_videos_" + getNow ( ) ,
294
303
expectBlobTypes : [ "video/mp4" , "image/jpeg" ] ,
295
304
data : this . videoToDownload
296
305
. map ( ( _ , i ) => {
@@ -345,7 +354,7 @@ export default {
345
354
if ( ! total ) return ;
346
355
let success = 0 ;
347
356
await download ( {
348
- folderName : "tiktok_musics" ,
357
+ folderName : "tiktok_musics_" + getNow ( ) ,
349
358
data : this . audioToDownload . map ( ( _ , i ) => ( {
350
359
url : _ . music . playUrl ,
351
360
filename :
You can’t perform that action at this time.
0 commit comments