Use HEAD method in loadImageHashFromPetName fetch
This commit is contained in:
parent
30718988b3
commit
261f19a270
1 changed files with 1 additions and 0 deletions
|
|
@ -58,6 +58,7 @@ const PETS_CP_URL_PATTERN =
|
|||
/https?:\/\/pets\.neopets\.com\/cp\/([a-z0-9]+)\/[0-9]+\/[0-9]+\.png/;
|
||||
async function loadImageHashFromPetName(petName) {
|
||||
const res = await fetch(`https://pets.neopets.com/cpn/${petName}/1/1.png`, {
|
||||
method: "HEAD",
|
||||
redirect: "manual",
|
||||
});
|
||||
if (res.status !== 302) {
|
||||
|
|
|
|||
Loading…
Reference in a new issue