fix issue #51

This commit fixes issue #51