File tree Expand file tree Collapse file tree 1 file changed +3
-5
lines changed
lib/jekyll-import/importers Expand file tree Collapse file tree 1 file changed +3
-5
lines changed Original file line number Diff line number Diff line change @@ -15,7 +15,7 @@ def self.specify_options(c)
1515 end
1616
1717 def self . process ( opts )
18- options = { directory => opts . fetch ( "directory" , "" ) }
18+ options = { : directory => opts . fetch ( "directory" , "" ) }
1919
2020 FileUtils . mkdir_p ( "_posts" )
2121 FileUtils . mkdir_p ( "_drafts" )
@@ -28,11 +28,9 @@ def self.process(opts)
2828 end
2929
3030 def self . traverse_posts_within ( directory , &block )
31- Dir . foreach ( directory ) do |fd |
31+ Dir . each_child ( directory ) do |fd |
3232 path = File . join ( directory , fd )
33- if fd . include? ( "." ) || fd . include? ( ".." )
34- next
35- elsif File . directory? ( path )
33+ if File . directory? ( path )
3634 traverse_posts_within ( path , &block )
3735 elsif path . end_with? ( "xml" )
3836 yield ( path ) if block_given?
You can’t perform that action at this time.
0 commit comments