don’t override :custom if already set
Sometimes Sprockets needs to access `options[:custom][:sprockets_context]`. If this is set, it should not be overridden. This happens when building a LivingStyleGuide file when the Sass source uses `asset-path`, `image-url` or similar functions.
This commit is contained in:
parent
e4b7d4fff0
commit
a5c65bac53
|
@ -105,7 +105,7 @@ module Middleman
|
||||||
filename: eval_file,
|
filename: eval_file,
|
||||||
line: line,
|
line: line,
|
||||||
syntax: syntax,
|
syntax: syntax,
|
||||||
custom: { middleman_context: ctx.app }
|
custom: (options[:custom] || {}).merge(middleman_context: ctx.app)
|
||||||
}
|
}
|
||||||
|
|
||||||
if ctx.is_a?(::Middleman::TemplateContext) && file
|
if ctx.is_a?(::Middleman::TemplateContext) && file
|
||||||
|
|
Loading…
Reference in a new issue