That seems like a good idea.  I'm not able to find anything definitive about leading or trailing whitespace around a section, but I don't see any harm in making this more tolerant of whitespace.  I will create a new pull request.