fix(pipeline): change variable declarations from var to def for consistency

Signed-off-by: 孙振宇 <>
This commit is contained in:
孙振宇 2025-01-17 17:16:56 +08:00
parent d37849f18b
commit 1896034cde

View File

@ -20,7 +20,7 @@ def call(Map configurations) {
stage("Source Codes Checkout") {
steps {
scripts {
var sourceFetcher = new SourceFetcher(this)
def sourceFetcher = new SourceFetcher(this)
sourceFetcher.fetch(configurations)
}
}
@ -37,7 +37,7 @@ def call(Map configurations) {
stage("Commit Linting If Enabled") {
steps {
scripts {
enabled = "${configurations.COMMIT_MESSAGE_LINT_ENABLED}"
def enabled = "${configurations.COMMIT_MESSAGE_LINT_ENABLED}"
if (enabled == "true") {
print("Commit Linting is enabled")