reduce redundant code

@bitgeeky too much extra code removing it.