remove commented code, const ref everything