simpler scanning of light ids in get-light

i don’t know what changed to make the old code break but this is now
simpler than before