Skip to content

Commit

Permalink
[pocketbase#2527] removed unnecessary slice check
Browse files Browse the repository at this point in the history
  • Loading branch information
KunalSin9h authored May 22, 2023
1 parent 4f5aa6f commit c370d84
Showing 1 changed file with 0 additions and 3 deletions.
3 changes: 0 additions & 3 deletions tools/list/list.go
Original file line number Diff line number Diff line change
Expand Up @@ -27,9 +27,6 @@ func SubtractSlice[T comparable](base []T, subtract []T) []T {

// ExistInSlice checks whether a comparable element exists in a slice of the same type.
func ExistInSlice[T comparable](item T, list []T) bool {
if len(list) == 0 {
return false
}

for _, v := range list {
if v == item {
Expand Down

0 comments on commit c370d84

Please sign in to comment.