@eaton How did you get assigning fields to the r function to type-check?! And why not just use local variables for index and items?