diff --git a/src/JobDslGenUtil.groovy b/src/JobDslGenUtil.groovy index f823eca..0b326b2 100644 --- a/src/JobDslGenUtil.groovy +++ b/src/JobDslGenUtil.groovy @@ -32,13 +32,13 @@ class JobDslGenUtil { creds.each { provider -> out.println " Checking credentials provider '$provider'" def cred = provider.credentials.findResult { it.id == credentialsId ? it : null } - if (cred?.class?.name == 'com.cloudbees.plugins.credentials.impl.UsernamePasswordCredentialsImpl') + if (cred?.class?.name == 'com.cloudbees.plugins.credentials.impl.UsernamePasswordCredentialsImpl') { out.println " Checking credentials provider 'UsernamePasswordCredentialsImpl'" out.println " Lengths ${cred.password?.size()} : ${cred.username?.size()}" ret = [ cred.password, cred.username ] - else if (cred?.class?.name == 'org.jenkinsci.plugins.plaincredentials.impl.StringCredentialsImpl') { + } else if (cred?.class?.name == 'org.jenkinsci.plugins.plaincredentials.impl.StringCredentialsImpl') { out.println " Checking credentials provider 'StringCredentialsImpl'" - out.println " Lengths ${cred.secret?.size()}" + out.println " Lengths ${cred.secret?.size()} : ${cred.username?.size()}" ret = [ cred.secret ] } }