fix for issue #22