Skip to content

Commit 5b00d54

Browse files
committed
revert: 撤回 WebView UA 覆盖(与验证码失败无关)
1 parent cad2bfc commit 5b00d54

1 file changed

Lines changed: 1 addition & 12 deletions

File tree

Lines changed: 1 addition & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,5 @@
11
package com.monkeycode.mobile;
22

3-
import android.os.Bundle;
43
import com.getcapacitor.BridgeActivity;
54

6-
public class MainActivity extends BridgeActivity {
7-
@Override
8-
protected void onCreate(Bundle savedInstanceState) {
9-
super.onCreate(savedInstanceState);
10-
// 移除 WebView UA 中的 "wv" 标识,避免被验证码检测为机器人
11-
getBridge().getWebView().getSettings().setUserAgentString(
12-
"Mozilla/5.0 (Linux; Android 14) AppleWebKit/537.36 " +
13-
"(KHTML, like Gecko) Chrome/124.0.0.0 Mobile Safari/537.36"
14-
);
15-
}
16-
}
5+
public class MainActivity extends BridgeActivity {}

0 commit comments

Comments
 (0)