[JENKINS-11078] prevent NPE
Merge pull request #30 from jenkinsci/JENKINS-11078

[JENKINS-11078] prevent NPE