fix a minor bug and document some stuff while I was at it