FIX: sub-categories with the same name had the same background image

This commit is contained in:
Régis Hanol
2015-02-12 18:21:07 +01:00
parent 8ec4d07bf2
commit 7b8c7ff3ef
8 changed files with 26 additions and 21 deletions

View File

@@ -50,7 +50,7 @@ class DiscourseSassImporter < Sass::Importers::Filesystem
contents = ""
Category.where('background_url IS NOT NULL').each do |c|
if c.background_url.present?
contents << "body.category-#{c.slug} { background-image: url(#{c.background_url}) }\n"
contents << "body.category-#{c.full_slug} { background-image: url(#{c.background_url}) }\n"
end
end
return Sass::Engine.new(contents, options.merge(