diff --git a/lib/rubocop/platform.rb b/lib/rubocop/platform.rb index ae5dcbd1f78..dfdc5146110 100644 --- a/lib/rubocop/platform.rb +++ b/lib/rubocop/platform.rb @@ -5,7 +5,7 @@ module RuboCop # on. module Platform def self.windows? - RUBY_PLATFORM =~ /cygwin|mswin|mingw|bccwin|wince|emx/ + RbConfig::CONFIG['host_os'] =~ /cygwin|mswin|mingw|bccwin|wince|emx/ end end end