Skip to content

Commit

Permalink
fix: Windows有头,Linux无头
Browse files Browse the repository at this point in the history
  • Loading branch information
14790897 committed Jul 9, 2024
1 parent 02bc934 commit 5a39ded
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion bypasscf.js
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ async function launchBrowserForUser(username, password) {
try {
var { connect } = await import("puppeteer-real-browser");
const { page, browser } = await connect({
headless: process.env.ENVIRONMENT !== "dev", // 当ENVIRONMENT不是'dev'时启用无头模式
headless: auto, // 当ENVIRONMENT不是'dev'时启用无头模式
args: ["--no-sandbox", "--disable-setuid-sandbox"], //linux需要
defaultViewport: {
width: 1280,
Expand Down

0 comments on commit 5a39ded

Please sign in to comment.