Fixes issue #266