diff --git a/share/pdf2htmlEX.js.in b/share/pdf2htmlEX.js.in
index 2ce4928..af97da9 100644
--- a/share/pdf2htmlEX.js.in
+++ b/share/pdf2htmlEX.js.in
@@ -47,7 +47,7 @@ var pdf2htmlEX = (function(){
this.n = parseInt(this.$p.data('page-no'), 16);
this.$b = $('.'+CSS_CLASS_NAMES['page_content_box'], this.$p);
- this.$d = this.$p.parents('.'+CSS_CLASS_NAMES['page_decoration']);
+ this.$d = this.$p.parent('.'+CSS_CLASS_NAMES['page_decoration']);
this.h = this.$p.height(); // Need to make rescale work when page_content_box is not loaded, yet
this.w = this.$p.width();
diff --git a/test/test.py b/test/test.py
index cddbf45..ccaf9cc 100755
--- a/test/test.py
+++ b/test/test.py
@@ -13,7 +13,7 @@ with open('out.html','w') as outf:
if not f.lower().endswith('.pdf'):
continue
print f
- if os.system('pdf2htmlEX -l 10 --optimize-text 1 --no-drm 1 --fit-width 1024 --dest-dir html --external-hint-tool="ttfautohint" "%s/%s"' % (DIR,f)) != 0:
+ if os.system('pdf2htmlEX -l 10 --no-drm 1 --fit-width 1024 --dest-dir html --external-hint-tool="ttfautohint" "%s/%s"' % (DIR,f)) != 0:
print "error on ", f
sys.exit(-1)