cleaned code and TODOs