Make Site#configure_theme more understandable
This commit is contained in:
parent
b937757dce
commit
4420c3b2af
|
@ -423,15 +423,14 @@ module Jekyll
|
||||||
|
|
||||||
private
|
private
|
||||||
def configure_theme
|
def configure_theme
|
||||||
self.theme = nil
|
self.theme =
|
||||||
return unless config["theme"]
|
if config["theme"].is_a?(String)
|
||||||
|
Jekyll::Theme.new(config["theme"])
|
||||||
if config["theme"].is_a?(String)
|
else
|
||||||
self.theme = Jekyll::Theme.new(config["theme"])
|
Jekyll.logger.warn "Theme:", "value of 'theme' in config should be "
|
||||||
else
|
"String to use gem-based themes, but got #{config["theme"].class}"
|
||||||
Jekyll.logger.warn "Theme:",
|
nil
|
||||||
"value of 'theme' in config should be String, but got #{config["theme"].class}"
|
end
|
||||||
end
|
|
||||||
end
|
end
|
||||||
|
|
||||||
private
|
private
|
||||||
|
|
Loading…
Reference in New Issue