Skip to content

Commit 20ac53b

Browse files
committed
[增加]1. 增加代理的参数检查
1 parent 3b006c3 commit 20ac53b

1 file changed

Lines changed: 6 additions & 1 deletion

File tree

GameFrameX.Core/Hotfix/HotfixModule.cs

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -387,13 +387,18 @@ private bool AddEvent(Type type)
387387
/// <returns>是否添加成功。</returns>
388388
private bool AddAgent(Type type)
389389
{
390-
type.CheckNotNull(nameof(type));
390+
ArgumentNullException.ThrowIfNull(type, nameof(type));
391391
if (!type.IsImplWithInterface(typeof(IComponentAgent)))
392392
{
393393
return false;
394394
}
395395

396396
var fullName = type.FullName;
397+
if (fullName == null)
398+
{
399+
return false;
400+
}
401+
397402
if (fullName == "GameFrameX.Launcher.Logic.Server.ServerComp")
398403
{
399404
return false;

0 commit comments

Comments
 (0)