array reverse fix