5.5: vine support and bug fixes

- added support for vine archives
- fixed ability to download muted videos from tumblr
- removed extra instagram id testing which i left by mistake
This commit is contained in:
wukko
2023-04-29 22:26:49 +06:00
parent 6e097de2db
commit a25615982c
8 changed files with 64 additions and 4 deletions

View File

@ -10,5 +10,5 @@ export default async function(obj) {
if (!html) return { error: 'ErrorCouldntFetch' };
if (!html.includes('property="og:video" content="https://va.media.tumblr.com/')) return { error: 'ErrorEmptyDownload' };
return { urls: `https://va.media.tumblr.com/${html.split('property="og:video" content="https://va.media.tumblr.com/')[1].split('"')[0]}`, audioFilename: `tumblr_${obj.id}_audio` }
return { urls: `https://va.media.tumblr.com/${html.split('property="og:video" content="https://va.media.tumblr.com/')[1].split('"')[0]}`, filename: `tumblr_${obj.id}.mp4`, audioFilename: `tumblr_${obj.id}_audio` }
}

View File

@ -0,0 +1,8 @@
export default async function(obj) {
let post = await fetch(`https://archive.vine.co/posts/${obj.id}.json`).then((r) => { return r.json() }).catch(() => { return false });
if (!post) return { error: 'ErrorEmptyDownload' };
if (post.videoUrl) return { urls: post.videoUrl.replace("http://", "https://"), filename: `vine_${obj.id}.mp4`, audioFilename: `vine_${obj.id}_audio` };
return { error: 'ErrorEmptyDownload' }
}