Trying to handle arrays uniformly is why it breaks. I don't see how this suggestion improves things.