Fix array access for php versions <= 5.4