summaryrefslogtreecommitdiff
path: root/src/scraper/scrape.js
diff options
context:
space:
mode:
Diffstat (limited to 'src/scraper/scrape.js')
-rw-r--r--src/scraper/scrape.js5
1 files changed, 2 insertions, 3 deletions
diff --git a/src/scraper/scrape.js b/src/scraper/scrape.js
index 131ae40..a24d1e8 100644
--- a/src/scraper/scrape.js
+++ b/src/scraper/scrape.js
@@ -1,12 +1,13 @@
const puppeteer = require('puppeteer');
const mongodb = require('mongodb')
+
// Specifically for scraping
// Stores in database once finished scraping
// query is the search string (title of movie or show) and the type (music, show, movie)
// will be used
-async function performSearch(query, type) {
+exports.performSearch = async function(query, type) {
const browser = await puppeteer.launch({
headless: true
});
@@ -29,5 +30,3 @@ async function performSearch(query, type) {
// do the database storage
await browser.close();
}
-
-// performSearch('spongebob', 'tv'); \ No newline at end of file