Fix bug in generating documentation instructions