fix bad var reference
Merge pull request #158 from dobbymoodge/beta2

fix bad var reference