Fix `resolveNames` by passing scope around