Fix: FreeTube Subscription Import

This commit is contained in:
ChunkyProgrammer 2023-08-01 10:46:12 -07:00
parent eba287e955
commit de50a8fc6c

View file

@ -105,10 +105,15 @@ export default {
}
// FreeTube DB
else if (text.indexOf("allChannels") != -1) {
const json = JSON.parse(text);
json.subscriptions.forEach(item => {
this.subscriptions.push(item.id);
});
const lines = text.split("\n");
for (let i = 0; i < lines.length; i++) {
if (lines[i] !== "") {
const json = JSON.parse(lines[i]);
json.subscriptions.forEach(item => {
this.subscriptions.push(item.id);
});
}
}
}
// Google Takeout JSON
else if (text.indexOf("contentDetails") != -1) {