Fix setContent to actually await the inner evaluation (#209)

This commit is contained in:
Andrey Lushnikov 2017-08-04 00:23:04 -07:00 committed by JoelEinbinder
parent af2b790227
commit 00196e6cdc

View File

@ -252,7 +252,7 @@ class Page extends EventEmitter {
* @return {!Promise}
*/
async setContent(html) {
this.evaluate(html => {
await this.evaluate(html => {
document.open();
document.write(html);
document.close();