mirror of
https://github.com/stashapp/stash.git
synced 2025-12-06 08:26:00 +01:00
Avoid redundant break statements (#1705)
In Go, a switch-case automatically breaks on end. This makes the break statement redundant.
This commit is contained in:
parent
e7f6cb22b7
commit
4545da9af0
1 changed files with 0 additions and 4 deletions
|
|
@ -209,20 +209,16 @@ func getIntCriterionWhereClause(column string, input models.IntCriterionInput) (
|
||||||
switch input.Modifier {
|
switch input.Modifier {
|
||||||
case "EQUALS", "NOT_EQUALS":
|
case "EQUALS", "NOT_EQUALS":
|
||||||
args = []interface{}{input.Value}
|
args = []interface{}{input.Value}
|
||||||
break
|
|
||||||
case "LESS_THAN":
|
case "LESS_THAN":
|
||||||
args = []interface{}{input.Value}
|
args = []interface{}{input.Value}
|
||||||
break
|
|
||||||
case "GREATER_THAN":
|
case "GREATER_THAN":
|
||||||
args = []interface{}{input.Value}
|
args = []interface{}{input.Value}
|
||||||
break
|
|
||||||
case "BETWEEN", "NOT_BETWEEN":
|
case "BETWEEN", "NOT_BETWEEN":
|
||||||
upper := 0
|
upper := 0
|
||||||
if input.Value2 != nil {
|
if input.Value2 != nil {
|
||||||
upper = *input.Value2
|
upper = *input.Value2
|
||||||
}
|
}
|
||||||
args = []interface{}{input.Value, upper}
|
args = []interface{}{input.Value, upper}
|
||||||
break
|
|
||||||
}
|
}
|
||||||
|
|
||||||
return column + " " + binding, args
|
return column + " " + binding, args
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue