scope a leaky var. fixes #403