fixes #59. correct variable declarations