Update index.md

Using square brackets here insinuates that this function takes an array; in reality, it takes an object.