Previously, calling directory("/hi") would error, because
options would remain nil if self doesn't respond_to?(:options) So, just double check we have something in options
This commit is contained in:
parent
bcc3000860
commit
9add993129
@ -17,6 +17,7 @@ module Compass
|
|||||||
# create a directory and all the directories necessary to reach it.
|
# create a directory and all the directories necessary to reach it.
|
||||||
def directory(dir, options = nil)
|
def directory(dir, options = nil)
|
||||||
options ||= self.options if self.respond_to?(:options)
|
options ||= self.options if self.respond_to?(:options)
|
||||||
|
options ||= {}
|
||||||
if File.exists?(dir) && File.directory?(dir)
|
if File.exists?(dir) && File.directory?(dir)
|
||||||
# logger.record :exists, basename(dir) unless options[:quiet]
|
# logger.record :exists, basename(dir) unless options[:quiet]
|
||||||
elsif File.exists?(dir)
|
elsif File.exists?(dir)
|
||||||
|
Loading…
Reference in New Issue
Block a user