Commit 6b64fbf7 6b64fbf7bd0b263fa81e37434f85950a76f1378f by Laurent Jouanneau

Add comments

1 parent 3bf3df38
...@@ -925,11 +925,13 @@ Casper.prototype.getPageContent = function getPageContent() { ...@@ -925,11 +925,13 @@ Casper.prototype.getPageContent = function getPageContent() {
925 if (!head || !body) { 925 if (!head || !body) {
926 return null; 926 return null;
927 } 927 }
928 // for content in Webkit
928 if (head.childNodes.length === 0 && 929 if (head.childNodes.length === 0 &&
929 body.childNodes.length === 1 && 930 body.childNodes.length === 1 &&
930 __utils__.findOne('body pre[style]')) { 931 __utils__.findOne('body pre[style]')) {
931 return __utils__.findOne('body pre').textContent.trim(); 932 return __utils__.findOne('body pre').textContent.trim();
932 } 933 }
934 // for content in Gecko
933 if (head.childNodes.length === 1 && 935 if (head.childNodes.length === 1 &&
934 body.childNodes.length === 1 && 936 body.childNodes.length === 1 &&
935 head.childNodes[0].localName === 'link' && 937 head.childNodes[0].localName === 'link' &&
......