SQLStore: use bool pointer instead of string (#18111)
(cherry picked from commit d9f01cb822)
This commit is contained in:
committed by
Leonard Gram
parent
ae04813045
commit
1f482a5f0b
@@ -456,14 +456,9 @@ func SearchUsers(query *models.SearchUsersQuery) error {
|
||||
whereParams = append(whereParams, queryWithWildcards, queryWithWildcards, queryWithWildcards)
|
||||
}
|
||||
|
||||
if query.IsDisabled != "" {
|
||||
param, err := strconv.ParseBool(query.IsDisabled)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
|
||||
if query.IsDisabled != nil {
|
||||
whereConditions = append(whereConditions, "is_disabled = ?")
|
||||
whereParams = append(whereParams, param)
|
||||
whereParams = append(whereParams, query.IsDisabled)
|
||||
}
|
||||
|
||||
if query.AuthModule != "" {
|
||||
|
||||
Reference in New Issue
Block a user