lib/polyfill/v2_4/dir.rb in polyfill-0.6.0 vs lib/polyfill/v2_4/dir.rb in polyfill-0.7.0
- old
+ new
@@ -1,9 +1,11 @@
-require_relative 'dir/class'
-
module Polyfill
module V2_4
module Dir
- include Class
+ module ClassMethods
+ def empty?(path_name)
+ exist?(path_name) && (entries(path_name) - ['.', '..']).empty?
+ end
+ end
end
end
end