mirror of
https://github.com/SecurityBrewery/catalyst.git
synced 2026-11-02 12:18:19 +01:00
Replace interface{} with any (#538)
Co-authored-by: Jonas Plum <git@jonasplum.de>
This commit is contained in:
1 parent
9200c865f8
commit
fb69a1a07b
6 files changed
+192
-193
No files matched your search
+4
-4
@@ -693,9 +693,9 @@ func (s *aqlInterpreter) function(ctx *parser.Function_callContext) {
|
||||
}
|
||||
}
|
||||
|
||||
func unique(array []interface{}) []interface{} {
|
||||
seen := map[interface{}]bool{}
|
||||
var filtered []interface{}
|
||||
func unique(array []any) []any {
|
||||
seen := map[any]bool{}
|
||||
var filtered []any
|
||||
for _, e := range array {
|
||||
_, ok := seen[e]
|
||||
if !ok {
|
||||
@@ -707,7 +707,7 @@ func unique(array []interface{}) []interface{} {
|
||||
return filtered
|
||||
}
|
||||
|
||||
func contains(values []interface{}, e interface{}) bool {
|
||||
func contains(values []any, e any) bool {
|
||||
for _, v := range values {
|
||||
if e == v {
|
||||
return true
|
||||
|
||||
Reference in new issue
Block a user