updated with a test for an issue 78