would be better to protect this section by if (Jenkins.instance.getPlugin("multiple-scm") != null) ... and do direct method invocation with fully qualified class name (no import)