fix important bug + added test
Merge pull request #642 from georgebyelas/master

fix important and nasty bug + added test