fixup #674 - should test .length instead of .ptr