Cleanup syntax in System max_open_file_descriptors

This commit is contained in:
Ryan Cobb 2019-04-26 10:16:53 -06:00
parent bb27bf4a1c
commit 2f6a1e77bc

View file

@ -27,11 +27,9 @@ module Gitlab
def self.max_open_file_descriptors
match = File.read('/proc/self/limits').match(/Max open files\s*(\d+)/)
if match && match[1]
max_fds = match[1].to_i
end
return unless match && match[1]
max_fds
match[1].to_i
end
def self.process_start_time