Skip to content

Commit 859e4dd

Browse files
authored
Merge pull request #25284 from abpframework/EngincanV/vfs-exclusion-filters
Pass ExclusionFilters to ReplaceEmbeddedByPhysical for letting developers define which files should be included or excluded
2 parents fdc6d30 + 6bf1905 commit 859e4dd

1 file changed

Lines changed: 9 additions & 1 deletion

File tree

framework/src/Volo.Abp.VirtualFileSystem/Volo/Abp/VirtualFileSystem/VirtualFileSetListExtensions.cs

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -65,6 +65,14 @@ private static IFileProvider CreateFileProvider(
6565
public static void ReplaceEmbeddedByPhysical<T>(
6666
[NotNull] this VirtualFileSetList fileSets,
6767
[NotNull] string physicalPath)
68+
{
69+
ReplaceEmbeddedByPhysical<T>(fileSets, physicalPath, ExclusionFilters.Sensitive);
70+
}
71+
72+
public static void ReplaceEmbeddedByPhysical<T>(
73+
[NotNull] this VirtualFileSetList fileSets,
74+
[NotNull] string physicalPath,
75+
ExclusionFilters exclusionFilters)
6876
{
6977
Check.NotNull(fileSets, nameof(fileSets));
7078
Check.NotNullOrWhiteSpace(physicalPath, nameof(physicalPath));
@@ -83,7 +91,7 @@ public static void ReplaceEmbeddedByPhysical<T>(
8391
thisPath = Path.Combine(thisPath, embeddedVirtualFileSet.BaseFolder!);
8492
}
8593

86-
fileSets[i] = new PhysicalVirtualFileSetInfo(new PhysicalFileProvider(thisPath), thisPath);
94+
fileSets[i] = new PhysicalVirtualFileSetInfo(new PhysicalFileProvider(thisPath, exclusionFilters), thisPath);
8795
}
8896
}
8997
}

0 commit comments

Comments
 (0)