diff --git a/src/Libraries/CoreNodes/List.cs b/src/Libraries/CoreNodes/List.cs index 0288c0b7e03..0ca35948502 100644 --- a/src/Libraries/CoreNodes/List.cs +++ b/src/Libraries/CoreNodes/List.cs @@ -625,6 +625,15 @@ public static IList ShiftIndices(IList list, int amount) [IsVisibleInDynamoLibrary(true)] public static object GetItemAtIndex(IList list, int index) { + if (index<0) + { + index = list.Count + index; + } + + if (index >= list.Count || index < 0) + { + throw new IndexOutOfRangeException(); + } return list[index]; }