remove unused code segment