fix typos and get it to compile (argh)