sdfsdf
This commit is contained in:
@@ -23,7 +23,7 @@ class SeleniumBrowser {
|
||||
.then(body => body.getAttribute('innerHTML'))
|
||||
let htmlPromise = this.isCaptchaPage(html) ? this.resolveCaptcha(driver) : this.getHtml(driver, html, params)
|
||||
html = await htmlPromise
|
||||
this.pool.release(driver)
|
||||
this.pool.destroy(driver)
|
||||
return html
|
||||
})
|
||||
} else {
|
||||
|
||||
@@ -40,9 +40,10 @@ class PoolingService {
|
||||
return driver.getSession().then(s => {
|
||||
logger.info('Driver session validation checked (id: %s)', s.getId())
|
||||
return true
|
||||
}).catch(err => {
|
||||
}).catch(err => {
|
||||
this.pool.destroy(driver)
|
||||
logger.debug({ message: err.message }, 'Driver session expired and destroy it')
|
||||
return this.pool.destroy(driver).then(() => false)
|
||||
return false
|
||||
})
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user