fixes #83 and fixes #80