Skip to content

Commit

Permalink
Fixing type check bug
Browse files Browse the repository at this point in the history
  • Loading branch information
g0ne150 committed Mar 31, 2024
1 parent fb52356 commit 67d8ddb
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions limiter.go
Original file line number Diff line number Diff line change
Expand Up @@ -40,9 +40,9 @@ func newLimiterExceptions(l *Limiter) {

// FileInput、KafkaInput have its own rate limiting. Unlike other inputs we not just dropping requests, we can slow down or speed up request emittion.
switch input := l.plugin.(type) {
case FileInput:
case *FileInput:
input.speedFactor = speedFactor
case KafkaInput:
case *KafkaInput:
input.speedFactor = speedFactor
}
}
Expand All @@ -66,9 +66,9 @@ func (l *Limiter) isLimitedExceptions() bool {
}
// Fileinput、Kafkainput have its own limiting algorithm
switch l.plugin.(type) {
case FileInput:
case *FileInput:
return true
case KafkaInput:
case *KafkaInput:
return true
default:
return false
Expand Down

0 comments on commit 67d8ddb

Please sign in to comment.