Array access fix