#49 fix edge case, modify test page to use sort