fixes issue #227