Skip to content

Commit

Permalink
πŸ› οΈ μ‘λ‹΅μ½”λ“œ μ—λŸ¬ ν•΄κ²°
Browse files Browse the repository at this point in the history
κΈ°μ‘΄μ—” 응닡 μ½”λ“œκ°€ 200이 μ•„λ‹ˆλ”λΌλ„ μ˜€νƒκ°μ§€ μ½”λ“œλ§Œ μ—†μœΌλ©΄ 결과둜 μΆ”κ°€λ˜λŠ” 점을 μˆ˜μ •

# ν˜„μž¬ React, Next λ“±λ“± μ„œλ²„μ‚¬μ΄λ“œ λ Œλ”λ§ 앱듀에 λŒ€ν•œ μ˜€νƒκ°μ§€ 데이터 μˆ˜μ • ν•„μš”
  • Loading branch information
36hjt8dv committed Jun 22, 2024
1 parent 553822d commit 8494a47
Showing 1 changed file with 13 additions and 10 deletions.
23 changes: 13 additions & 10 deletions index.html
Original file line number Diff line number Diff line change
Expand Up @@ -74,16 +74,19 @@

url = url.replace("{}", username);

await fetch(url).then((res) => {
if(res.status === 200 && fast) {
addResult(username, website, url);
}
return res.text();
}).then((text) => {
if(!text.includes(website.user_not_found)) {
addResult(username, website, url);
}
}).catch(() => {}) // user not found
const res = await fetch(url).catch(() => false);

if(!res || res.status !== 200) return;

if(fast) {
addResult(username, website, url);
};

const text = await res.text();

if(!text.includes(website.user_not_found)) {
addResult(username, website, url);
}
}))
}
}
Expand Down

0 comments on commit 8494a47

Please sign in to comment.