Skip to content

Commit 826827a

Browse files
committed
Merge pull request #1935 from xzyfer/fix/import-cache
Don't use import resource cache if there are custom importers
2 parents 0a05c8d + ad462f4 commit 826827a

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

src/context.cpp

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -351,8 +351,9 @@ namespace Sass {
351351

352352
// process the resolved entry
353353
else if (resolved.size() == 1) {
354+
bool use_cache = c_importers.size() == 0;
354355
// use cache for the resource loading
355-
if (sheets.count(resolved[0].abs_path)) return resolved[0];
356+
if (use_cache && sheets.count(resolved[0].abs_path)) return resolved[0];
356357
// try to read the content of the resolved file entry
357358
// the memory buffer returned must be freed by us!
358359
if (char* contents = read_file(resolved[0].abs_path)) {

0 commit comments

Comments
 (0)