Handle keys in arrays