Skip to content

Commit

Permalink
rubocop: Use squeeze instead of gsub
Browse files Browse the repository at this point in the history
Signed-off-by: Christian Menges <[email protected]>
  • Loading branch information
Garfield96 committed Jun 20, 2023
1 parent 21ca454 commit 0a57185
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/fluent/plugin/in_tail.rb
Original file line number Diff line number Diff line change
Expand Up @@ -778,7 +778,7 @@ def initialize(target_info, pe, log, read_from_head, follow_inodes, update_watch
attr_accessor :group_watcher

def tag
@parsed_tag ||= @path.tr('/', '.').gsub(/\.+/, '.').gsub(/^\./, '')
@parsed_tag ||= @path.tr('/', '.').squeeze('.').gsub(/^\./, '')
end

def register_watcher(watcher)
Expand Down

0 comments on commit 0a57185

Please sign in to comment.