removing `unwraps()` and replacing them with propper error handling remove unnecessary `clone()` calls
improve division of code into different modules