bugfixes needed for Issue #90