mirror of
https://github.com/gohugoio/hugo.git
synced 2025-08-27 22:09:53 +02:00
@@ -44,9 +44,6 @@ func (ns *Namespace) Complement(seqs ...interface{}) (interface{}, error) {
|
||||
sl := reflect.MakeSlice(v.Type(), 0, 0)
|
||||
for i := 0; i < v.Len(); i++ {
|
||||
ev, _ := indirectInterface(v.Index(i))
|
||||
if !ev.Type().Comparable() {
|
||||
return nil, errors.New("elements in complement must be comparable")
|
||||
}
|
||||
if _, found := aset[normalize(ev)]; !found {
|
||||
sl = reflect.Append(sl, ev)
|
||||
}
|
||||
|
Reference in New Issue
Block a user