Fixes for issue #53