DEV: Fix incorrect optimization in SvgSprite.

`SvgSprite.custom_sprite_paths` does not just fetch custom SVG sprite
from themes. It also picks up any custom svg icons from a pre-defined
plugin folder.

Follow-up to 0700e9382d
This commit is contained in:
Alan Guo Xiang Tan 2021-06-02 10:36:16 +08:00
parent 0700e9382d
commit ca9e0ee40b

View File

@ -322,7 +322,6 @@ License - https://fontawesome.com/license/free (Icons: CC BY 4.0, Fonts: SIL OFL
end
end
if theme_ids.present?
custom_svg_sprites(theme_ids).each do |fname|
svg_file = Nokogiri::XML(File.open(fname)) do |config|
config.options = Nokogiri::XML::ParseOptions::NOBLANKS
@ -340,7 +339,6 @@ License - https://fontawesome.com/license/free (Icons: CC BY 4.0, Fonts: SIL OFL
end
end
end
end
svg_subset << '</svg>'
end