mirror of
https://github.com/MinecraftForge/MinecraftForge.git
synced 2026-11-28 07:55:53 +00:00
Fix potential index exception in ForgeDirection
This commit is contained in:
1 parent
fc430243d1
commit
bed6c410b6
1 file changed
+1
-1
@@ -40,7 +40,7 @@ public enum ForgeDirection
|
||||
|
||||
public static ForgeDirection getOrientation(int id)
|
||||
{
|
||||
if (id < ForgeDirection.values().length)
|
||||
if (id > 0 && id < ForgeDirection.values().length)
|
||||
{
|
||||
return ForgeDirection.values()[id];
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user