nm, am looking at `idx` incorrectly