fix for #248 number 2

Last fix didn't work, this one should though
Merge pull request #362 from VampyrBytes/master

fix for #248 number 2