mirror of
https://github.com/elastic/logstash.git
synced 2025-04-24 14:47:19 -04:00
parent
8a28d2fe84
commit
7a73c5fd7b
1 changed files with 1 additions and 5 deletions
|
@ -53,7 +53,7 @@ module LogStash module Config module Source
|
|||
|
||||
config_string = ::File.read(file)
|
||||
|
||||
if valid_encoding?(config_string)
|
||||
if config_string.valid_encoding?
|
||||
part = org.logstash.common.SourceWithMetadata.new("file", file, 0, 0, config_string)
|
||||
config_parts << part
|
||||
else
|
||||
|
@ -101,10 +101,6 @@ module LogStash module Config module Source
|
|||
all_files - get_matched_files
|
||||
end
|
||||
|
||||
def valid_encoding?(content)
|
||||
content.ascii_only? && content.valid_encoding?
|
||||
end
|
||||
|
||||
def temporary_file?(filepath)
|
||||
filepath.match(TEMPORARY_FILE_RE)
|
||||
end
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue