cleaned up treereader