From c1c35ce39e96bcdd941f0b3711bbb08a0c5992d9 Mon Sep 17 00:00:00 2001 From: Thorsten Eckel Date: Fri, 8 May 2015 12:47:25 +0200 Subject: [PATCH] Corrected with rubocop cop 'Style/GlobalVars'. --- .rubocop.yml | 2 -- script/websocket-server.rb | 8 ++++---- 2 files changed, 4 insertions(+), 6 deletions(-) diff --git a/.rubocop.yml b/.rubocop.yml index faaa7f11e..77808fc90 100644 --- a/.rubocop.yml +++ b/.rubocop.yml @@ -187,8 +187,6 @@ Style/Documentation: Style/CommentIndentation: Enabled: false -Style/GlobalVars: - Enabled: false Lint/RescueException: Enabled: false Style/ClassVars: diff --git a/script/websocket-server.rb b/script/websocket-server.rb index de379f649..b4b29f331 100755 --- a/script/websocket-server.rb +++ b/script/websocket-server.rb @@ -76,10 +76,10 @@ if ARGV[0] == 'start' && @options[:d] Daemons.daemonize # create pid file - $daemon_pid = File.new( @options[:i].to_s, 'w' ) - $daemon_pid.sync = true - $daemon_pid.puts(Process.pid.to_s) - $daemon_pid.close + daemon_pid = File.new( @options[:i].to_s, 'w' ) + daemon_pid.sync = true + daemon_pid.puts(Process.pid.to_s) + daemon_pid.close end @clients = {}