XFE Git
XFE Studio Git
Git 首页 全局搜索
XFE 主站 文档 NuGet

XFEExtension.NetCore.ServerInteractive

[DLL] Server interaction extension, including user identity verification and querying in conjunction with AutoConfig

公开
关注 0 Fork 0 Star 0
返回提交历史

XFEstudio/XFEExtension.NetCore.ServerInteractive

fix: address code review feedback - improve docs and simplify null handling

Agent-Logs-Url: https://github.com/XFEstudio/XFEExtension.NetCore.ServerInteractive/sessions/2a0c1e13-19b9-4694-8959-523c6d627a1a Co-authored-by: XFEstudio <132526994+XFEstudio@users.noreply.github.com>

8cf683c
copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
提交于

代码差异

2 个文件 +3 -3
Modified XFEExtension.NetCore.ServerInteractive.SourceGenerator/EntryPointGenerator.cs +2 -2
@@ -136,7 +136,7 @@ public class EntryPointGenerator : IIncrementalGenerator
136 136
137 137 foreach (var attr in entryPointAttributes)
138 138 {
139 var path = attr.ConstructorArguments.FirstOrDefault().Value?.ToString() ?? "*";
139 var path = attr.ConstructorArguments.FirstOrDefault().Value?.ToString();
140 140 // 空路径或 "*" 均视为全匹配通配符
141 141 if (string.IsNullOrEmpty(path))
142 142 path = "*";
@@ -145,7 +145,7 @@ public class EntryPointGenerator : IIncrementalGenerator
145 145 containingType.ContainingNamespace.ToDisplayString(),
146 146 containingType.Name,
147 147 methodSymbol.Name,
148 path,
148 path!,
149 149 isAsync,
150 150 isContainingTypePartial,
151 151 methodSymbol.Parameters.Length,
Modified XFEExtension.NetCore.ServerInteractive/Utilities/Helpers/RouteMatchHelper.cs +1 -1
@@ -15,7 +15,7 @@ internal static class RouteMatchHelper
15 15 /// <summary>
16 16 /// 将路由模式与实际路由进行通配符匹配
17 17 /// <para>支持的通配符:</para>
18 /// <para>- <c>*</c>:匹配任意路径</para>
18 /// <para>- <c>*</c>:匹配任意路径(空路径在源生成器中已被规范化为 <c>*</c>)</para>
19 19 /// <para>- <c>v1/*</c>:匹配 v1/ 后跟一个路径段</para>
20 20 /// <para>- <c>v1/*/test</c>:匹配 v1/ 后跟任意一个段再跟 /test</para>
21 21 /// </summary>