Skip to content

Commit

Permalink
revert: 不再支持国内域名
Browse files Browse the repository at this point in the history
  • Loading branch information
weaigc committed Sep 15, 2023
1 parent f5e18d7 commit 4c6c168
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 8 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ Bingo,一个让你呼吸顺畅 New Bing。

> 配置了 BING_COOKIE 意味着你将自己的账号共享给所有使用此服务的人,如果不需要免登录画图的功能,不建议设置此变量
打开 https://www.bing.com 并登录,然后访问 https://www.bing.com/turing/captcha/challenge ,通过人机校验(如果显示**无效域**则跳过校验不管),然后
打开 https://www.bing.com 并登录,然后访问 https://www.bing.com/turing/captcha/challenge ,通过人机校验(如果显示**无效域**意味着需要自行准备梯子),然后

![BING_COOKIE](./docs/images/curl.png)

Expand Down
8 changes: 1 addition & 7 deletions src/components/settings.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -37,16 +37,10 @@ export function Settings() {
try {
headerValue = atob(headerValue)
} catch (e) { }
if (!/^\s*curl ['"]https:\/\/(www|cn)\.bing\.com\/turing\/captcha\/challenge['"]/.test(headerValue)) {
if (!/^\s*curl ['"]https:\/\/www\.bing\.com\/turing\/captcha\/challenge['"]/.test(headerValue)) {
toast.error('用户信息格式不正确')
return
}
if (RegExp.$1 === 'cn') {
toast.error('你配置的国内域名 cn.bing.com 需要启用此选项')
setImageOnly(true)
setHistory(false)
return
}
setImageOnly(checked)
} else {
setImageOnly(checked)
Expand Down

0 comments on commit 4c6c168

Please sign in to comment.