Separated code into more modules