randydev commited on
Commit
3573915
·
verified ·
1 Parent(s): 88a2b59

Update plugins/alldownloader.js

Browse files
Files changed (1) hide show
  1. plugins/alldownloader.js +3 -6
plugins/alldownloader.js CHANGED
@@ -17,6 +17,7 @@ import {
17
  TeraboxDownloader,
18
  TeraboxV2Downloader,
19
  PinterestDownloader,
 
20
  InstagramDLV2,
21
  } from '../lib/all.js';
22
 
@@ -78,17 +79,14 @@ async function downloadMedia(media) {
78
  * 500:
79
  * description: Internal Server Error
80
  */
81
-
82
-
83
  AllDlRoutes.get('/api/v1/dl/xnxxsearch-v2', apiLimiter, async (req, res) => {
84
  try {
85
  const q = req.query.q;
86
 
87
  if (!q) {
88
- return res.status(400).json({ error: "URL parameter is required." });
89
  }
90
- // const results = await testings.default.search(q);
91
- // const results = await xnxxSearch(q);
92
  res.json({ message: "ok" });
93
  // console.dir(testings);
94
  } catch (error) {
@@ -96,7 +94,6 @@ AllDlRoutes.get('/api/v1/dl/xnxxsearch-v2', apiLimiter, async (req, res) => {
96
  }
97
  });
98
 
99
-
100
  /**
101
  * @swagger
102
  * /api/v1/dl/instagram-v2:
 
17
  TeraboxDownloader,
18
  TeraboxV2Downloader,
19
  PinterestDownloader,
20
+ XsearchDownloaderV2,
21
  InstagramDLV2,
22
  } from '../lib/all.js';
23
 
 
79
  * 500:
80
  * description: Internal Server Error
81
  */
 
 
82
  AllDlRoutes.get('/api/v1/dl/xnxxsearch-v2', apiLimiter, async (req, res) => {
83
  try {
84
  const q = req.query.q;
85
 
86
  if (!q) {
87
+ return res.status(400).json({ error: "q parameter is required." });
88
  }
89
+ const results = await XsearchDownloaderV2(q);
 
90
  res.json({ message: "ok" });
91
  // console.dir(testings);
92
  } catch (error) {
 
94
  }
95
  });
96
 
 
97
  /**
98
  * @swagger
99
  * /api/v1/dl/instagram-v2: