Skip to content

Commit

Permalink
fixed (again) reflection
Browse files Browse the repository at this point in the history
  • Loading branch information
FoxWorn3365 committed Jun 6, 2024
1 parent c68fafe commit 0816aac
Showing 1 changed file with 6 additions and 3 deletions.
9 changes: 6 additions & 3 deletions UncomplicatedCustomRoles/Manager/RespawnTimerCompatibility.cs
Original file line number Diff line number Diff line change
Expand Up @@ -24,16 +24,19 @@ internal class RespawnTimerCompatibility

internal static bool GetReplaceHelper(out Type TimerView)
{
if (!Allowed)
{
TimerView = null;
return false;
}

TimerView = RespawnTimer.Assembly.GetType("RespawnTimer.API.Features.TimerView");
if (TimerView is null)
{
Log.Debug("Compatibility loader for RespawnTimer failed: no class 'RespawnTimer.API.Features.TimerView' present!");
return false;
}

if (TimerView.GetProperty("ReplaceHelper") is null)
return false;

return true;
}

Expand Down

0 comments on commit 0816aac

Please sign in to comment.