Implemented all TODO's