Files
codeql/go/ql/test/query-tests/RedundantCode/DuplicateCondition/DuplicateCondition.go
2026-06-11 07:15:54 +02:00

12 lines
195 B
Go

package main
func controller(msg string) {
if msg == "start" { // $ Source
start()
} else if msg == "start" { // $ Alert // NOT OK
stop()
} else {
panic("Message not understood.")
}
}