Skip to content

refactor(app): replace redundant boolean closure in makeAppStageStatus with id > 0 (#6992) - #7026

Open
Tyagiquamar wants to merge 1 commit into
devtron-labs:mainfrom
Tyagiquamar:fix/6992-make-app-stage-status
Open

refactor(app): replace redundant boolean closure in makeAppStageStatus with id > 0 (#6992)#7026
Tyagiquamar wants to merge 1 commit into
devtron-labs:mainfrom
Tyagiquamar:fix/6992-make-app-stage-status

Conversation

@Tyagiquamar

Copy link
Copy Markdown

Closes #6992

Description

In \pkg/app/appDetails/read/AppDetailsReadService.go, \makeAppStageStatus\ initialized the \Status\ field using an inline anonymous closure:

\\go
Status: func() bool {
if id > 0 {
return true
} else {
return false
}
}(),
\\

This replaces the closure with the direct boolean expression \Status: id > 0, removing the per-call function execution while preserving the exact boolean logic.

@bito-code-review

Copy link
Copy Markdown

Bito Review Skipped - Source Branch Not Found

Bito didn't review this change because the pull request is no longer valid. It may have been merged, or the source/target branch may no longer exist.

@sonarqubecloud

sonarqubecloud Bot commented Sep 9, 2026

Copy link
Copy Markdown

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Refactor: replace redundant boolean closure in makeAppStageStatus with id > 0

1 participant