Fixed NPE when no lastSuccessfulBuild is available.