mirror of
https://codeberg.org/ashley/poke.git
synced 2024-11-13 03:18:07 +01:00
add new dislikes stuff :3
This commit is contained in:
parent
65c9953f05
commit
9c82e1fadf
1 changed files with 5 additions and 2 deletions
|
@ -41,11 +41,14 @@ class PokeTubeAPI {
|
||||||
* @private
|
* @private
|
||||||
*/
|
*/
|
||||||
async _getEngagementData() {
|
async _getEngagementData() {
|
||||||
const fallbackUrl = `https://returnyoutubedislikeapi.com/votes?videoId=${this.videoId}`;
|
var url = [`https://p.poketube.fun/api?v=${this.videoId}&hash=d0550b6e28c8f93533a569c314d5b4e2`, `https://returnyoutubedislikeapi.com/votes?videoId=${this.videoId}`]
|
||||||
|
const dislikes =
|
||||||
|
url[Math.floor(Math.random() * url.length)];
|
||||||
|
|
||||||
|
|
||||||
const { fetch } = await import("undici");
|
const { fetch } = await import("undici");
|
||||||
|
|
||||||
const engagement = await fetch(fallbackUrl).then((res) => res.json());
|
const engagement = await fetch(dislikes).then((res) => res.json());
|
||||||
return engagement;
|
return engagement;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue