Use let, not def. Fix docs