Skip to content

Commit

Permalink
Fix hcaptcha iframe URL parsing
Browse files Browse the repository at this point in the history
  • Loading branch information
Androbin committed Dec 6, 2023
1 parent 39248f1 commit 0aacf1a
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,7 @@ export class HcaptchaContentScript {

private _extractInfoFromIframes(iframes: HTMLIFrameElement[]) {
return iframes
.map(el => el.src.replace('.html#', '.html?'))
.map(el => el.src.replace('#', el.src.includes('?') ? '&' : '?'))
.map(url => {
const { searchParams } = new URL(url)
const result: types.CaptchaInfo = {
Expand Down

0 comments on commit 0aacf1a

Please sign in to comment.