From: notmasteryet Date: Fri, 23 Sep 2011 01:18:43 +0000 (-0500) Subject: intermediate variable for document.body X-Git-Url: https://git.parisson.com/?a=commitdiff_plain;h=f3e4cf20cc6d4173ec45669d26f05cf929da10a7;p=pdf.js.git intermediate variable for document.body --- diff --git a/test/driver.js b/test/driver.js index db6c9b5..3e30971 100644 --- a/test/driver.js +++ b/test/driver.js @@ -57,8 +57,9 @@ function cleanup() { styleSheet.deleteRule(0); } var guard = document.getElementById('content-end'); - while (document.body.lastChild != guard) - document.body.removeChild(document.body.lastChild); + var body = document.body; + while (body.lastChild != guard) + body.removeChild(body.lastChild); } function nextTask() {