29 ArgumentNullException.ThrowIfNull(methodName);
31 var authorityType = typeof(TAuthority);
32 var authorityMethod = authorityType.GetMethod(methodName)
33 ??
throw new InvalidOperationException($
"Could not find method {methodName} on {authorityType}!");
36 ??
throw new InvalidOperationException($
"Could not find method {authorityType}.{methodName}() has no {nameof(TgsAuthorizeAttribute)}!");
39 Roles = authorizeAttribute.Roles;