Added partial 'fcuk' (Exploited College Girls) scraper. Added file parameter for actor names and scene URLs.
This commit is contained in:
16
src/utils/file-entries.js
Normal file
16
src/utils/file-entries.js
Normal file
@@ -0,0 +1,16 @@
|
||||
'use strict';
|
||||
|
||||
const fs = require('fs');
|
||||
|
||||
async function getFileEntries(location) {
|
||||
if (!location) {
|
||||
throw new Error('No filepath provided');
|
||||
}
|
||||
|
||||
const file = await fs.promises.readFile(location, 'utf-8');
|
||||
const entries = file.split(/\n/).map(entry => entry.trim()).filter(Boolean);
|
||||
|
||||
return entries;
|
||||
}
|
||||
|
||||
module.exports = getFileEntries;
|
||||
Reference in New Issue
Block a user