v0.8.9-SNAPSHOT fix double result in getSecret

This commit is contained in:
az 2021-04-19 21:02:21 +02:00
parent 5baedbb32e
commit b3afde6c93
2 changed files with 5 additions and 2 deletions

View file

@ -14,7 +14,7 @@ apply plugin: 'java-test-fixtures'
apply plugin: 'maven-publish'
group = 'io.provs'
version = '0.8.8'
version = '0.8.9-SNAPSHOT'
repositories {
mavenCentral()
@ -40,12 +40,16 @@ test {
compileJava.options.debugOptions.debugLevel = "source,lines,vars"
compileTestJava.options.debugOptions.debugLevel = "source,lines,vars"
sourceCompatibility = 1.11
targetCompatibility = 1.11
// https://stackoverflow.com/questions/21904269/configure-gradle-to-publish-sources-and-javadoc
java {
withSourcesJar()
withJavadocJar()
}
dependencies {
implementation "org.jetbrains.kotlin:kotlin-stdlib:$kotlin_version"
implementation "org.jetbrains.kotlin:kotlin-reflect:$kotlin_version"

View file

@ -161,7 +161,6 @@ open class Prov protected constructor(private val processor: Processor, val name
*/
fun getSecret(command: String): Secret? {
val result = cmdNoLog(command)
addResultToEval(ProvResult(result.success, err = result.err, exception = result.exception, exit = result.exit))
return if (result.success && result.out != null) {
addResultToEval(ProvResult(true, getCallingMethodName()))
Secret(result.out)