rename project to fetch-booru

This commit is contained in:
Conduitry 2024-03-23 19:17:41 -04:00
parent c6e1f31cec
commit 06791a1baf
3 changed files with 3 additions and 3 deletions

View File

@ -1,4 +1,4 @@
# dl-fur
# fetch-booru
## `[hostname].json` fetch options

View File

@ -4,7 +4,7 @@ import { log } from './log.js';
const fetch_options_lookup = {};
export async function fetch_retry(url) {
const { hostname } = new URL(url);
const fetch_options = await (fetch_options_lookup[hostname] ??= fs.promises.readFile(new URL(`../${hostname}.json`, import.meta.url), 'utf8').then(JSON.parse).catch(() => ({ headers: { 'user-agent': 'dl-fur (+https://git.chor.date/Conduitry/dl-fur)' } })));
const fetch_options = await (fetch_options_lookup[hostname] ??= fs.promises.readFile(new URL(`../${hostname}.json`, import.meta.url), 'utf8').then(JSON.parse).catch(() => ({ headers: { 'user-agent': 'fetch-booru (+https://git.chor.date/Conduitry/fetch-booru)' } })));
for (;;) {
let resp;
try {

2
package-lock.json generated
View File

@ -1,5 +1,5 @@
{
"name": "dl-fur",
"name": "fetch-booru",
"lockfileVersion": 3,
"requires": true,
"packages": {