removed some redundant code

Signed-off-by: Graham Chiu <compkarori@gmail.com>