[JENKINS-23641] - Handle possible nulls if Git checkout fails

My Java fu is weak and my understanding of Jenkins internals is even weaker, but won't this still throw an exception if the "last build revision" is not available?

Is the fix that an exception is thrown, but execution is not halted and the build will not fail?