style and documentation fixes

Thanks to @kynan.