From e8eda8170c124a93830c95c0e2433d085a560645 Mon Sep 17 00:00:00 2001 From: gewuyou <95328647+GeWuYou@users.noreply.github.com> Date: Sat, 25 Apr 2026 09:35:33 +0800 Subject: [PATCH] =?UTF-8?q?fix(routing):=20=E6=B8=85=E7=90=86=20RouterBase?= =?UTF-8?q?=20=E5=AE=88=E5=8D=AB=E5=BC=82=E6=AD=A5=E7=AD=89=E5=BE=85?= =?UTF-8?q?=E7=9A=84=20MA0004?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - 修复 RouterBase 进入守卫异步调用缺少 ConfigureAwait(false) 的机械型 MA0004 - 修复 RouterBase 离开守卫异步调用缺少 ConfigureAwait(false) 的机械型 MA0004 --- GFramework.Game/Routing/RouterBase.cs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/GFramework.Game/Routing/RouterBase.cs b/GFramework.Game/Routing/RouterBase.cs index 1f731505..3fe43f54 100644 --- a/GFramework.Game/Routing/RouterBase.cs +++ b/GFramework.Game/Routing/RouterBase.cs @@ -140,7 +140,7 @@ public abstract class RouterBase : AbstractSystem try { Log.Debug("Executing enter guard: {0} for {1}", guard.GetType().Name, routeKey); - var canEnter = await guard.CanEnterAsync(routeKey, context); + var canEnter = await guard.CanEnterAsync(routeKey, context).ConfigureAwait(false); if (!canEnter) { @@ -182,7 +182,7 @@ public abstract class RouterBase : AbstractSystem try { Log.Debug("Executing leave guard: {0} for {1}", guard.GetType().Name, routeKey); - var canLeave = await guard.CanLeaveAsync(routeKey); + var canLeave = await guard.CanLeaveAsync(routeKey).ConfigureAwait(false); if (!canLeave) { @@ -241,4 +241,4 @@ public abstract class RouterBase : AbstractSystem } #endregion -} \ No newline at end of file +}