Unverified Commit 1e31a3e0 authored by Keshav Prasad's avatar Keshav Prasad Committed by GitHub
Browse files

fix: array out of bound exception handler

Showing with 2 additions and 2 deletions
+2 -2
......@@ -16,9 +16,9 @@ def call(String buildStatus) {
slack_status = 'good'
build_status = "Succeded"
}
envDir = sh(returnStdout: true, script: "echo $JOB_NAME").split('/')[-3].trim()
channel_env_name = envDir.toUpperCase() + "_NOTIFY_SLACK_CHANNEL"
try {
envDir = sh(returnStdout: true, script: "echo $JOB_NAME").split('/')[-3].trim()
channel_env_name = envDir.toUpperCase() + "_NOTIFY_SLACK_CHANNEL"
slack_channel = evaluate "$channel_env_name".replace('-', '')
slackSend (
channel: slack_channel,
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment