Skip to content

Commit fe68c8d

Browse files
authored
Fix lint error (#4698)
Signed-off-by: JamesMurkin <jamesmurkin@hotmail.com>
1 parent 93ddb76 commit fe68c8d

File tree

1 file changed

+0
-21
lines changed

1 file changed

+0
-21
lines changed

internal/scheduleringester/dbops.go

Lines changed: 0 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -448,27 +448,6 @@ func mergeInMap[M ~map[K]V, K comparable, V any](a M, b DbOperation) bool {
448448
return false
449449
}
450450

451-
// mergeListMaps merges an op b into a, provided that b is of the same type as a.
452-
// If merged, the resulting map will contain all keys from a and b
453-
// In case both a and b have the same key, the values for that key will be combined
454-
// Returns true if the ops were merged and false otherwise.
455-
func mergeListMaps[M ~map[K][]V, K comparable, V any](a M, b DbOperation) bool {
456-
// Using a type switch here, since using a type assertion
457-
// (which should also work in theory) crashes the go1.19 compiler.
458-
switch op := b.(type) {
459-
case M:
460-
for k, v := range op {
461-
if _, present := a[k]; present {
462-
a[k] = append(a[k], v...)
463-
} else {
464-
a[k] = v
465-
}
466-
}
467-
return true
468-
}
469-
return false
470-
}
471-
472451
func (a InsertJobs) CanBeAppliedBefore(b DbOperation) bool {
473452
// We don't check for job and run ops here,
474453
// since job and run ops can never appear before the corresponding InsertJobs.

0 commit comments

Comments
 (0)