harden renderNote, remove debug logging