- changed return types to be more precise
- added tests