Fix scoping problem. Fixes #38.