minor rewrite fixes #1