Skip to content

Commit

Permalink
fix: timeout=0 not set bug
Browse files Browse the repository at this point in the history
  • Loading branch information
jamesyang.yjm committed Aug 3, 2019
1 parent 750c70a commit 8226752
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion index.js
Original file line number Diff line number Diff line change
Expand Up @@ -137,7 +137,7 @@ async function main({
// goto url
if(userAgent) page.setUserAgent(userAgent)
if(viewport) page.setViewport(viewport)
if(timeout) page.setDefaultNavigationTimeout(timeout)
if(timeout != null) page.setDefaultNavigationTimeout(timeout)
if(cookies) page.setCookie(...cookies)
onBeforeOpen && await onBeforeOpen(page)
await page.goto(url, openOption)
Expand Down

0 comments on commit 8226752

Please sign in to comment.