Remove dead code in lib/