fixes for issue #30