aboutsummaryrefslogtreecommitdiff
path: root/lib/consumet/manga/getChapters.js
diff options
context:
space:
mode:
Diffstat (limited to 'lib/consumet/manga/getChapters.js')
-rw-r--r--lib/consumet/manga/getChapters.js4
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/consumet/manga/getChapters.js b/lib/consumet/manga/getChapters.js
index 7a19bbc..ee6eabe 100644
--- a/lib/consumet/manga/getChapters.js
+++ b/lib/consumet/manga/getChapters.js
@@ -1,7 +1,7 @@
let API_URL;
-API_URL = process.env.API_URI;
+API_URL = process.env.API_URI || null || null;
// remove / from the end of the url if it exists
-if (API_URL.endsWith("/")) {
+if (API_URL && API_URL.endsWith("/")) {
API_URL = API_URL.slice(0, -1);
}