fixes #15, fixes #13