diff --git a/nginx_stage/lib/nginx_stage/socket_file.rb b/nginx_stage/lib/nginx_stage/socket_file.rb index f8889b80e3..162d866ee3 100644 --- a/nginx_stage/lib/nginx_stage/socket_file.rb +++ b/nginx_stage/lib/nginx_stage/socket_file.rb @@ -1,3 +1,5 @@ +# frozen_string_literal: true + require 'pathname' module NginxStage @@ -27,9 +29,8 @@ def socket # Delete the socket from the file system def delete @socket.delete - rescue - $stderr.puts "Unable to delete socket file at #{socket}" + rescue StandardError + warn "Unable to delete socket file at #{socket}" end - end end