mirror of
https://codeberg.org/ashley/poke.git
synced 2024-11-17 08:34:42 -05:00
continuations!!!
This commit is contained in:
parent
5cd19daa7e
commit
5715ecdb96
1 changed files with 10 additions and 1 deletions
11
server.js
11
server.js
|
@ -459,8 +459,17 @@ app.get("/old/watch", async function (req, res) {
|
|||
app.get("/search", async (req, res) => {
|
||||
const { toJson } = require("xml2json");
|
||||
const query = req.query.query;
|
||||
|
||||
if(req.query.continuation){
|
||||
var continuation = req.query.continuation
|
||||
}
|
||||
|
||||
if(!req.query.continuation){
|
||||
var continuation = ""
|
||||
}
|
||||
|
||||
const search = await fetch(
|
||||
`https://tube.kuylar.dev/api/search?query=${query}`
|
||||
`https://tube.kuylar.dev/api/search?query=${query}&continuation=${continuation}`
|
||||
);
|
||||
|
||||
const text = await search.text();
|
||||
|
|
Loading…
Reference in a new issue