cleaned some redundant logical checking
added TODOs