完善大部分问题

This commit is contained in:
橙子
2022-04-08 23:44:25 +08:00
parent 5fcd4fb5a4
commit feb73174eb
26 changed files with 160 additions and 160 deletions

View File

@@ -8,6 +8,7 @@ using System.Text;
using Yi.Framework.Common.Const;
using Yi.Framework.Common.Helper;
using Yi.Framework.Common.IOCOptions;
using Yi.Framework.Core;
namespace Yi.Framework.WebCore.MiddlewareExtend
{
@@ -19,7 +20,7 @@ namespace Yi.Framework.WebCore.MiddlewareExtend
public static IServiceCollection AddJwtService(this IServiceCollection services)
{
services.Configure<JWTTokenOptions>(Appsettings.appConfiguration("JwtAuthorize"));
services.AddTransient<JwtInvoker>();
var jwtOptions = Appsettings.app<JWTTokenOptions>("JwtAuthorize");
services.AddAuthentication(JwtBearerDefaults.AuthenticationScheme)
.AddJwtBearer(options =>