|
@@ -111,13 +111,13 @@ namespace GxPress.Api
|
|
|
{
|
|
|
app.UseDeveloperExceptionPage();
|
|
|
}
|
|
|
-
|
|
|
+ app.UseMvc();
|
|
|
//最上层的自定义异常处理中间件
|
|
|
app.UseMiddleware<ExceptionMiddleware>();
|
|
|
app.UseRouting();
|
|
|
app.UseJwtAuthorization();
|
|
|
app.UseStaticFiles();
|
|
|
- app.UseCors("cors");
|
|
|
+ app.UseCors("AllowAny");
|
|
|
app.UseSwashbuckle();
|
|
|
|
|
|
app.UseEndpoints(endpoints =>
|