fixes debug assert
Merge pull request #3 from ederc/debug-fix

fixes debug assert