[graphspell][js] dawg: fix bugs in select()