NEXUS-6230: Backport to 2.7.x

Nullcheck was missing for listedGav
As the folder might contain maven metadata and other stuff
that M2GavCalculator cannot interpret, and will return
null.
Merge pull request #331 from sonatype/nexus-2.7.x-NEXUS-6230

[2.7.x] NEXUS-6230: Backport to 2.7.x