another typo and wrong variable

Signed-off-by: emanuele <emanuele45@gmail.com>
Merge pull request #275 from emanuele45/master

heck...I should test things...