trivial: fix then -> than typos in comments and documentation