Fixes #16 and front end tests