Bugfix for issue #78