Advertisement
Guest User

Untitled

a guest
Mar 29th, 2020
69
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.99 KB | None | 0 0
  1. const data = fs.readFileSync('D:/Users/andre/Desktop/PinkBat/PinkDownloads.txt', 'UTF-8');
  2. const lines = data.split(/\r?\n/);
  3. var yesorno = 0;
  4. //link start!
  5. lines.forEach((line) => {
  6. if (output == line) {
  7. yesorno = 1
  8. }
  9.  
  10. });
  11.  
  12. if (yesorno == 0) {
  13.  
  14.  
  15.  
  16. console.log(line);
  17. await downloadEpisode(playlist['uri'], tmpOutput, false)
  18. if (muxSubs && subtitles && subtitles.length) {
  19. info('Muxing...')
  20. await mux(subtitles, tmpOutput, output, debug)
  21. } else {
  22. info('Skipping mux...')
  23. }
  24. info(`Successfully downloaded "${output}"`)
  25. } else {
  26. await downloadEpisode(playlist['uri'], output)
  27. }
  28.  
  29. return
  30. }
  31. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement