Skip to content

Commit bbda510

Browse files
jeffreyrainyashwinimurt0xFA11
authored
fix: not using NativeArrayExtensions.IndexOf as this API changed in 21.0-pre.2 (#2303)
fix: not using NativeArrayExtensions.IndexOf as this API changed in 2.1.0-pre.2 Co-authored-by: ashwini <[email protected]> Co-authored-by: Fatih Mar <[email protected]>
1 parent 3716e27 commit bbda510

File tree

1 file changed

+2
-2
lines changed
  • com.unity.netcode.gameobjects/Runtime/NetworkVariable/Collections

1 file changed

+2
-2
lines changed

com.unity.netcode.gameobjects/Runtime/NetworkVariable/Collections/NetworkList.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -413,7 +413,7 @@ public void Clear()
413413
/// <inheritdoc />
414414
public bool Contains(T item)
415415
{
416-
int index = NativeArrayExtensions.IndexOf(m_List, item);
416+
int index = m_List.IndexOf(item);
417417
return index != -1;
418418
}
419419

@@ -426,7 +426,7 @@ public bool Remove(T item)
426426
throw new InvalidOperationException("Client is not allowed to write to this NetworkList");
427427
}
428428

429-
int index = NativeArrayExtensions.IndexOf(m_List, item);
429+
int index = m_List.IndexOf(item);
430430
if (index == -1)
431431
{
432432
return false;

0 commit comments

Comments
 (0)