Skip to content

Commit 9dbc95d

Browse files
authored
Merge pull request #21642 from abpframework/AllowedExtraWebContentFolders
Use `UseVirtualStaticFiles` for `AllowedExtraWebContentFolders` first.
2 parents f577e07 + 55aab15 commit 9dbc95d

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

framework/src/Volo.Abp.AspNetCore/Microsoft/AspNetCore/Builder/AbpApplicationBuilderExtensions.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -177,14 +177,14 @@ public static StaticAssetsEndpointConventionBuilder MapAbpStaticAssets(this IApp
177177
throw new AbpException("The app(IApplicationBuilder) is not an IEndpointRouteBuilder.");
178178
}
179179

180-
app.UseVirtualStaticFiles();
181-
182180
var options = app.ApplicationServices.GetRequiredService<IOptions<AbpAspNetCoreContentOptions>>().Value;
183181
foreach (var folder in options.AllowedExtraWebContentFolders)
184182
{
185183
app.UseVirtualStaticFiles(folder);
186184
}
187185

186+
app.UseVirtualStaticFiles();
187+
188188
return endpoints.MapStaticAssets(staticAssetsManifestPath);
189189
}
190190

0 commit comments

Comments
 (0)