File tree Expand file tree Collapse file tree 1 file changed +6
-7
lines changed
dsl/src/main/kotlin/com/code42/jenkins/pipelinekt/dsl/step/scripted Expand file tree Collapse file tree 1 file changed +6
-7
lines changed Original file line number Diff line number Diff line change @@ -7,22 +7,21 @@ import com.code42.jenkins.pipelinekt.internal.step.scripted.Try
7
7
8
8
@Suppress(" UnusedPrivateMember" )
9
9
fun DslContext <Step >.`try` (
10
- trySteps : DslContext <Step >.() -> Unit ,
11
- ` catch ` : (DslContext <Step >.() -> Unit )?
10
+ trySteps : DslContext <Step >.() -> Unit ,
11
+ catchSteps : (DslContext <Step >.() -> Unit )?
12
12
) {
13
- tryCatch(trySteps, ` catch ` )
13
+ tryCatch(trySteps, catchSteps )
14
14
}
15
15
16
16
fun DslContext<Step>.tryCatch (
17
- tryStep : DslContext <Step >.() -> Unit ,
18
- catchStep : (DslContext <Step >.() -> Unit )?
17
+ tryStep : DslContext <Step >.() -> Unit ,
18
+ catchStep : (DslContext <Step >.() -> Unit )?
19
19
) {
20
20
val trySteps = DslContext .into(tryStep).toStep()
21
- if (catchStep != null ) {
21
+ if (catchStep != null ) {
22
22
val catchSteps = DslContext .into(catchStep).toStep()
23
23
add(Try (trySteps, catchSteps))
24
24
} else {
25
25
add(Try (trySteps, null ))
26
26
}
27
27
}
28
-
You can’t perform that action at this time.
0 commit comments