Skip to content

Commit

Permalink
Fix invidious
Browse files Browse the repository at this point in the history
  • Loading branch information
OshekharO authored Aug 27, 2024
1 parent 13526ce commit fa9d57d
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions repo/invidious.io.js
Original file line number Diff line number Diff line change
@@ -1,21 +1,20 @@
// ==MiruExtension==
// @name Invidious
// @version v0.0.2
// @version v0.0.3
// @author OshekharO
// @lang all
// @license MIT
// @icon https://invidious.io/apple-touch-icon.png
// @package invidious.io
// @type bangumi
// @webSite https://vid.puffyan.us/api/v1
// @webSite https://iv.ggtyler.dev/api/v1
// ==/MiruExtension==

export default class extends Extension {
async latest() {
const res = await this.request(`/trending?region=US`);

if (!Array.isArray(res)) {
// Handle the case when the response is not an array
return [];
}

Expand Down Expand Up @@ -66,7 +65,7 @@ export default class extends Extension {

return {
type: "hls",
url: res.formatStreams?.[1]?.url,
url: res.formatStreams?.[0]?.url,
};
}
}

0 comments on commit fa9d57d

Please sign in to comment.