Fix
Browse files- plugins/alldownloader.js +4 -5
plugins/alldownloader.js
CHANGED
@@ -72,13 +72,13 @@ async function downloadMedia(media) {
|
|
72 |
* type: string
|
73 |
* - in: query
|
74 |
* name: custom_params
|
75 |
-
* required:
|
76 |
* description: Additional parameters for the request
|
77 |
* schema:
|
78 |
* type: string
|
79 |
* - in: query
|
80 |
* name: custom_search
|
81 |
-
* required:
|
82 |
* description: Search query
|
83 |
* schema:
|
84 |
* type: string
|
@@ -98,10 +98,9 @@ AllDlRoutes.get('/api/v1/custom/itzpire', apiLimiter, async (req, res) => {
|
|
98 |
const params = req.query.custom_params;
|
99 |
const search = req.query.custom_search;
|
100 |
|
101 |
-
if (!url
|
102 |
-
return res.status(400).json({ error: "
|
103 |
}
|
104 |
-
|
105 |
const results = await IzreCustom(url, params, search);
|
106 |
res.json({ message: results });
|
107 |
} catch (error) {
|
|
|
72 |
* type: string
|
73 |
* - in: query
|
74 |
* name: custom_params
|
75 |
+
* required: false
|
76 |
* description: Additional parameters for the request
|
77 |
* schema:
|
78 |
* type: string
|
79 |
* - in: query
|
80 |
* name: custom_search
|
81 |
+
* required: false
|
82 |
* description: Search query
|
83 |
* schema:
|
84 |
* type: string
|
|
|
98 |
const params = req.query.custom_params;
|
99 |
const search = req.query.custom_search;
|
100 |
|
101 |
+
if (!url) {
|
102 |
+
return res.status(400).json({ error: "parameters are required." });
|
103 |
}
|
|
|
104 |
const results = await IzreCustom(url, params, search);
|
105 |
res.json({ message: results });
|
106 |
} catch (error) {
|