mirror of
https://github.com/moparisthebest/www.moparscape.org
synced 2024-12-25 17:08:49 -05:00
removed incorrect usage of gsub! which was returning nil if the substitution was not found. Now strips leading and trailing whitespace
This commit is contained in:
parent
3587076aed
commit
ae51fe859e
@ -67,7 +67,7 @@ module Jekyll
|
|||||||
if @filetype
|
if @filetype
|
||||||
source += "{% highlight #{@filetype} %}\n" + code + "\n{% endhighlight %}</figure></div>"
|
source += "{% highlight #{@filetype} %}\n" + code + "\n{% endhighlight %}</figure></div>"
|
||||||
else
|
else
|
||||||
source += "<pre><code>" + code.gsub!(/</,'<') + "</code></pre></figure></div>"
|
source += "<pre><code>" + code.lstrip.rstrip.gsub(/</,'<') + "</code></pre></figure></div>"
|
||||||
end
|
end
|
||||||
partial = Liquid::Template.parse(source)
|
partial = Liquid::Template.parse(source)
|
||||||
context.stack do
|
context.stack do
|
||||||
|
Loading…
Reference in New Issue
Block a user